Skip to content

Commit

Permalink
Merge branch 'main' into ansible-replace-sfx-with-splunk-otel-dotnet
Browse files Browse the repository at this point in the history
  • Loading branch information
pjanotti authored Jan 23, 2025
2 parents 822b435 + 6c45b35 commit f80bcf3
Show file tree
Hide file tree
Showing 60 changed files with 128 additions and 2,950 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/chef-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ env:
jobs:
chef-lint-spec-test:
name: chef-lint-spec-test
# Use 20.04.5 until https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/16450 is resolved
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
steps:
- name: Check out the codebase.
uses: actions/checkout@v4
Expand All @@ -46,7 +45,7 @@ jobs:
make rake-spec
chef-kitchen-matrix:
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
steps:
- name: Check out code
uses: actions/checkout@v4
Expand Down Expand Up @@ -80,8 +79,7 @@ jobs:
win-matrix: ${{ steps.get-win-matrix.outputs.matrix }}

chef-kitchen-linux:
# Use 20.04.5 until https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/16450 is resolved
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
needs: [chef-lint-spec-test, chef-kitchen-matrix]
strategy:
matrix: ${{ fromJSON(needs.chef-kitchen-matrix.outputs.linux-matrix) }}
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/chef.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ permissions:
jobs:
push-release-tag:
name: Push Release Tag
# Use 20.04.5 until https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/16450 is resolved
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/integration-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ jobs:
- run: docker load -i ./docker-otelcol/${{ matrix.ARCH }}/image.tar
- run: ln -sf otelcol_linux_${{ matrix.ARCH }} ./bin/otelcol
- run: chmod a+x ./bin/*
- uses: shogo82148/actions-setup-redis@v1.35.1
- uses: shogo82148/actions-setup-redis@v1.38.0
if: matrix.PROFILE == 'integration'
with:
auto-start: false
Expand Down Expand Up @@ -298,7 +298,7 @@ jobs:
path: ./bin
- run: ln -sf otelcol_linux_amd64 ./bin/otelcol
- run: chmod a+x ./bin/*
- uses: shogo82148/actions-setup-redis@v1.35.1
- uses: shogo82148/actions-setup-redis@v1.38.0
if: matrix.PROFILE == 'integration'
with:
auto-start: false
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lychee.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- uses: actions/checkout@v4
- name: lychee Link Checker
id: lychee
uses: lycheeverse/lychee-action@v2.1.0
uses: lycheeverse/lychee-action@v2.2.0
with:
lycheeVersion: nightly # TODO: Change to stable once v0.17.1 is released, the version that includes a retry fix
args: -v -n --config .lychee.toml './*.md' './**/*.md'
Expand Down
66 changes: 61 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,69 @@

## Unreleased

## v0.117.0

This Splunk OpenTelemetry Collector release includes changes from the [opentelemetry-collector v0.117.0](https://github.com/open-telemetry/opentelemetry-collector/releases/tag/v0.117.0) and the [opentelemetry-collector-contrib v0.117.0](https://github.com/open-telemetry/opentelemetry-collector-contrib/releases/tag/v0.117.0) releases where appropriate.

### 🛑 Breaking changes 🛑

- (Contrib) `cloudfoundryreceiver`: Introduce a feature gate enable copying envelope tags to the metrics as resource attributes instead of datapoint attributes. ([#34824](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/34824))
- (Contrib) `pkg/ottl`: removed the ability to reference entire parent objects. ([#36872](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36872))
Statements like `set(cache["resource"], resource)` in non-resource contexts will no longer work.

- (Contrib) `routingconnector`: Change default value of `match_once` parameter to `true`. ([#29882](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/29882))
This field was deprecated in v0.116.0 and will be removed in v0.120.0.

- (Core) `otelcol`: Remove warnings when 0.0.0.0 is used ([#11713](https://github.com/open-telemetry/opentelemetry-collector/issues/11713), [#8510](https://github.com/open-telemetry/opentelemetry-collector/issues/8510))


### 🚩 Deprecations 🚩

- (Contrib) `sapmexporter`: Deprecate SAPM exporter ([#36028](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36028))
The SAPM exporter is being marked as deprecated. Please use the `otlphttp` exporter with the configuration shown
below. Also update your pipeline configuration for Traces accordingly.
```yaml
exporters:
otlphttp:
traces_endpoint: "${SPLUNK_INGEST_URL}/v2/trace/otlp"
headers:
"X-SF-Token": "${SPLUNK_ACCESS_TOKEN}"
```
### 🚀 New components 🚀
- (Splunk) Add `metricsgeneration` processor ([#5769](https://github.com/signalfx/splunk-otel-collector/pull/5769))

### 💡 Enhancements 💡

- (Splunk) Add a new discovery bundle for Envoy proxy metrics ([#5780](https://github.com/signalfx/splunk-otel-collector/pull/5780))
- (Contrib) `k8sclusterreceiver`: Add additional attributes to node and pod entities ([#35879](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/35879))
Adds the following attributes to node and pod metadata/entities:
- `k8s.pod.phase`: The phase of a Pod indicates where the Pod is in its lifecycle. E.g. 'Pending', 'Running'
- `k8s.pod.status_reason`: A brief message indicating details about why the pod is in this state. E.g. 'Evicted'
- `k8s.node.condition_*`: The condition of a node. e.g. `k8s.node.condition_ready`. The value can be `true`, `false`, `unknown`.

- (Contrib) `receivercreator`: Add support for starting logs' collection based on provided k8s annotations' hints ([#34427](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/34427))
- (Contrib) `ottl`: Add a new ottl trim function that trims leading and trailing characters from a string (default- whitespace). ([#34100](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/34100))
- (Contrib) `sqlqueryreceiver`: Add instrumentation scope to SQL query receiver metrics and logs ([#31028](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/31028))
- (Contrib) `statsdreceiver`: Add UDS support to statsdreceiver ([#21385](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/21385))
- (Contrib) `tailsamplingprocessor`: Support hot sampling policy loading ([#37014](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/37014))

### 🧰 Bug fixes 🧰

- (Splunk) Fix deprecation warning for multiline config source calls ([#5829](https://github.com/signalfx/splunk-otel-collector/pull/5829))
- (Contrib) `receiver/azureeventhub`: Ensure that observed timestamp is set when unmarshaling logs. ([#36861](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36861))
- (Contrib) `internal/docker`: Fix image matching regular expression to properly match SHA256 strings. ([#36239](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36239))
This affects the `docker_observer` extension.
- (Contrib) `k8sobjectsreceiver`: ensure the `k8s.namespace.name` attribute is set for objects retrieved using the `watch` mode ([#36352](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36352))
- (Contrib) `mongodbatlasreceiver`: Update the mongoDB Atlas receiver to use the Default HTTP Transport that supports default proxy configuration ([#36412](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36412))
- (Contrib) `mysqlreceiver`: Avoid recording a value for the MysqlBufferPoolPages metric when out-of-bounds. ([#35495](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/35495))
When using compressed tables, Innodb_buffer_pool_pages_misc may report an out-of-bounds value.
See https://bugs.mysql.com/bug.php?id=59550 for context.

- (Contrib) `pkg/ottl`: fix handling of nested maps within slices in the `flatten` function ([#36162](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/36162))
- (Contrib) `mysqlreceiver`: Divide large values directly in SQL queries to avoid int overflows ([#35495](https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/35495))
- (Core) `internal/sharedcomponent`: Fixed bug where sharedcomponent would use too much memory remembering all the previously reported statuses ([#11826](https://github.com/open-telemetry/opentelemetry-collector/issues/11826))

## v0.116.0

Expand Down Expand Up @@ -83,7 +139,7 @@ This Splunk OpenTelemetry Collector release includes changes from the [opentelem
- (Splunk) Automatic Discovery:
- Switch bundled NGINX discovery to create [OpenTelemetry NGINX receiver](https://docs.splunk.com/observability/en/gdi/opentelemetry/components/nginx-receiver.html#nginx-receiver) instead of the Smart Agent NGINX monitor ([#5689](https://github.com/signalfx/splunk-otel-collector/pull/5689))
- (Splunk) Expose internal metrics at default `localhost:8888` address instead of `${SPLUNK_LISTEN_INTERFACE}:8888` ([#5706](https://github.com/signalfx/splunk-otel-collector/pull/5706))
This can be changed in `service::telemetry::metrics` section:
This can be changed in `service::telemetry::metrics` section:
```yaml
service:
telemetry:
Expand Down Expand Up @@ -155,14 +211,14 @@ This Splunk OpenTelemetry Collector release includes changes from the [opentelem
### 🛑 Breaking changes 🛑

- (Splunk) Given that `SPLUNK_TRACE_URL` environment variable is deprecated and replaced with
`${SPLUNK_INGEST_URL}/v2/trace` in the default configurations, the option to set the Trace URL has been removed from
`${SPLUNK_INGEST_URL}/v2/trace` in the default configurations, the option to set the Trace URL has been removed from
all packaging and mass deployment solutions to an avoid confusion. ([#5672](https://github.com/signalfx/splunk-otel-collector/pull/5672)).

### 🧰 Bug fixes 🧰

- (Splunk) `receiver/journald`: Upgrade journald client libraries in the Collector docker image by taking them from latest Debian image.
This fixes journald receiver on kubernetes nodes with recent versions of systemd ([#5664](https://github.com/signalfx/splunk-otel-collector/pull/5664)).
- (Core) scraperhelper: If the scraper shuts down, do not scrape first. ([#11632](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/11632))
- (Splunk) `receiver/journald`: Upgrade journald client libraries in the Collector docker image by taking them from latest Debian image.
This fixes journald receiver on kubernetes nodes with recent versions of systemd ([#5664](https://github.com/signalfx/splunk-otel-collector/pull/5664)).
- (Core) scraperhelper: If the scraper shuts down, do not scrape first. ([#11632](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/11632))
When the scraper is shutting down, it currently will scrape at least once. With this change, upon receiving a shutdown order, the receiver's scraperhelper will exit immediately.
- (Contrib) `pkg/stanza`: Ensure that time parsing happens before entry is sent to downstream operators ([#36213](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/36213))
- (Contrib) `processor/k8sattributes`: Block when starting until the metadata have been synced, to fix that some data couldn't be associated with metadata when the agent was just started. ([#32556](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/32556))
Expand Down
29 changes: 0 additions & 29 deletions deployments/chef/kitchen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,6 @@ verifier:
name: inspec

platforms:
- name: amazonlinux-2
driver:
image: dokken/amazonlinux-2
pid_one_command: /usr/lib/systemd/systemd

- name: centos-9
driver:
image: dokken/centos-stream-9
Expand All @@ -51,35 +46,11 @@ platforms:
image: dokken/debian-12
pid_one_command: /bin/systemd

- name: opensuse-12
driver:
image: opensuse/leap:42
intermediate_instructions: |
ENV container docker
RUN sed -i 's|download.opensuse.org|ftp5.gwdg.de/pub/opensuse/discontinued|' /etc/zypp/repos.d/*.repo
RUN zypper -n clean && zypper -n refresh
RUN zypper -n install -l curl procps dbus-1 systemd-sysvinit tar wget hostname sudo
RUN (cd /usr/lib/systemd/system/sysinit.target.wants/; for i in *; do [ $i = \
"systemd-tmpfiles-setup.service" ] || rm -f $i; done); \
rm -f /usr/lib/systemd/system/multi-user.target.wants/*;\
rm -f /usr/lib/systemd/system/local-fs.target.wants/*; \
rm -f /usr/lib/systemd/system/sockets.target.wants/*udev*; \
rm -f /usr/lib/systemd/system/sockets.target.wants/*initctl*; \
rm -f /usr/lib/systemd/system/basic.target.wants/*;\
rm -f /usr/lib/systemd/system/anaconda.target.wants/*;
ENV init /sbin/init
pid_one_command: /sbin/init

- name: opensuse-15
driver:
image: dokken/opensuse-leap-15
pid_one_command: /usr/lib/systemd/systemd

- name: oraclelinux-7
driver:
image: dokken/oraclelinux-7
pid_one_command: /usr/lib/systemd/systemd

- name: oraclelinux-8
driver:
image: dokken/oraclelinux-8
Expand Down
1 change: 1 addition & 0 deletions deployments/cloudfoundry/bosh/DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ If no configuration file is provided, a template file will be populated using th

Required Properties:

- `cloudfoundry.deployment.hostname`
- `cloudfoundry.rlp_gateway.endpoint`
- `cloudfoundry.uaa.endpoint`
- `cloudfoundry.uaa.password`
Expand Down
3 changes: 3 additions & 0 deletions deployments/cloudfoundry/bosh/jobs/splunk-otel-collector/spec
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ properties:
description: "The Splunk realm in which your organization resides -- used to derive splunk.ingest_url and splunk.api_url if those are not provided"
required: false

cloudfoundry.director.hostname:
description: "The hostname of the Cloud Foundry BOSH director"

cloudfoundry.rlp_gateway.endpoint:
description: "The URL of the RLP Gateway that acts as a proxy for the firehose"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,11 @@ receivers:
<% end %>

processors:
resourcedetection:
detectors: [system]
resource:
attributes:
- key: host.name
value: <%= p('cloudfoundry.director.hostname') %>
action: upsert

exporters:
signalfx:
Expand All @@ -43,6 +46,6 @@ service:
pipelines:
metrics:
receivers: [cloudfoundry]
processors: [resourcedetection]
processors: [resource]
exporters: [signalfx]
<% end %>
2 changes: 2 additions & 0 deletions deployments/cloudfoundry/tile/tile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ packages:
release: splunk-otel-collector
properties:
cloudfoundry:
director:
hostname: (( $director.hostname ))
rlp_gateway:
endpoint: https://log-stream.(( ..cf.cloud_controller.system_domain.value ))
shard_id: (( .properties.cloudfoundry_rlp_gateway_shard_id.value ))
Expand Down
12 changes: 10 additions & 2 deletions docker/apachespark/long_running.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@
#

import time
import signal
import threading
import queue as Queue
from typing import Any, Callable, List, Tuple

from pyspark import SparkConf, SparkContext


def delayed(seconds: int) -> Callable[[Any], Any]:
def f(x: int) -> int:
time.sleep(seconds)
Expand Down Expand Up @@ -76,7 +76,15 @@ def run() -> List[Tuple[int, int]]:
print("Job results are:", result.get())
sc.stop()

def signal_handler(signal, frame):
global interrupted
interrupted = True

if __name__ == "__main__":
for i in range(100):
signal.signal(signal.SIGINT, signal_handler)
global interrupted
interrupted = False
while True:
main()
if interrupted:
break
1 change: 0 additions & 1 deletion docs/components.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ The distribution offers support for the following components.
| [scripted_inputs](../internal/receiver//scriptedinputsreceiver) | [in development] |
| [signalfx](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/signalfxreceiver) | [stable] |
| [signalfxgatewayprometheusremotewrite](https://github.com/signalfx/splunk-otel-collector/tree/main/internal/receiver/signalfxgatewayprometheusremotewritereceiver) | [in development] |
| [simpleprometheus](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/simpleprometheusreceiver) | [beta] |
| [smartagent](../pkg/receiver/smartagentreceiver) | [beta] |
| [snowflake](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/snowflakereceiver) | [beta] |
| [solace](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/solacereceiver) | [beta] |
Expand Down
2 changes: 1 addition & 1 deletion examples/prometheus-federation/prom-counter/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.23.4-bullseye
FROM golang:1.23.5-bullseye

WORKDIR /go/src/app

Expand Down
2 changes: 1 addition & 1 deletion examples/splunk-hec-traces/tracing/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.23.4-bullseye
FROM golang:1.23.5-bullseye

WORKDIR /go/src/app

Expand Down
2 changes: 1 addition & 1 deletion examples/splunk-hec/logging/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.23.4-bullseye
FROM golang:1.23.5-bullseye

WORKDIR /go/src/app

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ require (
github.com/open-telemetry/opentelemetry-collector-contrib/receiver/windowsperfcountersreceiver v0.117.0
github.com/open-telemetry/opentelemetry-collector-contrib/receiver/zipkinreceiver v0.117.0
github.com/prometheus/client_model v0.6.1
github.com/prometheus/common v0.61.0
github.com/prometheus/common v0.62.0
github.com/prometheus/prometheus v0.54.1
github.com/signalfx/splunk-otel-collector/pkg/extension/smartagentextension v0.83.0
github.com/signalfx/splunk-otel-collector/pkg/processor/timestampprocessor v0.83.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1612,8 +1612,8 @@ github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8b
github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo=
github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc=
github.com/prometheus/common v0.29.0/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls=
github.com/prometheus/common v0.61.0 h1:3gv/GThfX0cV2lpO7gkTUwZru38mxevy90Bj8YFSRQQ=
github.com/prometheus/common v0.61.0/go.mod h1:zr29OCN/2BsJRaFwG8QOBr41D6kkchKbpeNH7pAjb/s=
github.com/prometheus/common v0.62.0 h1:xasJaQlnWAeyHdUBeGjXmutelfJHWMRr+Fg4QszZ2Io=
github.com/prometheus/common v0.62.0/go.mod h1:vyBcEuLSvWos9B1+CyL7JZ2up+uFzXhkqml0W5zIY1I=
github.com/prometheus/common/sigv4 v0.1.0 h1:qoVebwtwwEhS85Czm2dSROY5fTo2PAPEVdDeppTwGX4=
github.com/prometheus/common/sigv4 v0.1.0/go.mod h1:2Jkxxk9yYvCkE5G1sQT7GuEXm57JrvHu9k5YwTjsNtI=
github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
Expand Down
16 changes: 12 additions & 4 deletions internal/configsource/source.go
Original file line number Diff line number Diff line change
Expand Up @@ -368,10 +368,18 @@ func resolveStringValue(ctx context.Context, configSources map[string]ConfigSour
}
default:
if deprecatedFormUsed {
printDeprecationWarningOnce(fmt.Sprintf(
"[WARNING] Config source expansion formatted as $uri:selector has been deprecated, "+
"use ${uri:selector[?params]} instead. Please replace $%s with ${%s} in your configuration",
expandableContent, expandableContent))
if strings.Contains(expandableContent, "\n") {
printDeprecationWarningOnce(fmt.Sprintf(
"[WARNING] Calling config sources in multiline format is deprecated. "+
"Please convert the following call to the one-line format ${uri:selector?param1"+
"=value1,param2=value2}:\n %s",
expandableContent))
} else {
printDeprecationWarningOnce(fmt.Sprintf(
"[WARNING] Config source expansion formatted as $uri:selector has been deprecated, "+
"use ${uri:selector[?params]} instead. Please replace $%s with ${%s} in your configuration",
expandableContent, expandableContent))
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="FluentAssertions" Version="7.0.0" />
<PackageReference Include="FluentAssertions" Version="8.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.12.0" />
<PackageReference Include="xunit" Version="2.9.3" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.2">
Expand Down
2 changes: 1 addition & 1 deletion packaging/release/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
PyGithub==2.5.0
boto3==1.35.97
boto3==1.36.2
docker==7.1.0
requests==2.32.3
Loading

0 comments on commit f80bcf3

Please sign in to comment.