Skip to content

Commit

Permalink
Merge branch 'main' into UpdateReadme
Browse files Browse the repository at this point in the history
  • Loading branch information
asreehari-splunk authored Oct 4, 2024
2 parents 2af558a + aee4a66 commit d66922c
Show file tree
Hide file tree
Showing 110 changed files with 3,156 additions and 2,048 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/chef-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ jobs:
run: |
kitchen test ${{ matrix.SUITE }}-${{ matrix.DISTRO }}
# For some reason, kitchen returns 0 here even if there are test failures, so check the log instead.
grep -q '0 failures' .kitchen/logs/kitchen.log || exit 1
grep -q "No tests executed." .kitchen/logs/kitchen.log && exit 1
grep -q "0 failures" .kitchen/logs/kitchen.log || exit 1
shell: bash
env:
KITCHEN_YAML: kitchen.windows.yml
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cla.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
steps:
- name: "CLA Assistant"
if: (github.event.comment.body == 'recheck' || github.event.comment.body == 'I have read the CLA Document and I hereby sign the CLA') || github.event_name == 'pull_request_target'
uses: cla-assistant/github-action@v2.5.2
uses: cla-assistant/github-action@v2.6.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PERSONAL_ACCESS_TOKEN: ${{ secrets.PAT_CLATOOL }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nomad.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
nomad: [ "1.6.2-1", "1.7.5-1" ]
nomad: [ "1.6.10-1", "1.7.7-1" ]
fail-fast: false
steps:
- name: Check out the codebase.
Expand Down
171 changes: 171 additions & 0 deletions .github/workflows/otelcol-fips.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,171 @@
name: "otelcol-fips"

on:
push:
branches:
- main
pull_request:
paths:
- '.github/workflows/otelcol-fips.yml'
- 'cmd/otelcol/**'
- 'internal/**'
- 'pkg/**'
- 'tests/**'
- 'Makefile'
- 'Makefile.Common'
- 'go.mod'
- 'go.sum'
- '!**.md'
- '!internal/buildscripts/**'

concurrency:
group: otelcol-fips-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

env:
GO_VERSION: "1.22.7"

jobs:
otelcol-fips:
runs-on: ${{ fromJSON('["ubuntu-20.04", "otel-arm64"]')[matrix.GOARCH == 'arm64'] }}
strategy:
matrix:
include:
- GOOS: linux
GOARCH: amd64
- GOOS: linux
GOARCH: arm64
- GOOS: windows
GOARCH: amd64
fail-fast: false
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: '**/go.sum'
- run: make otelcol-fips
env:
GOOS: ${{ matrix.GOOS }}
GOARCH: ${{ matrix.GOARCH }}
- uses: actions/upload-artifact@v4
with:
name: otelcol-fips-${{ matrix.GOOS }}-${{ matrix.GOARCH }}
path: ./bin/*

win-binary-test:
runs-on: windows-2022
needs: [ otelcol-fips ]
strategy:
matrix:
FIPSMODE: [ "1", "0" ]
fail-fast: false
steps:
- uses: actions/download-artifact@v4
with:
name: otelcol-fips-windows-amd64
path: ./bin
- run: Set-ItemProperty -Path HKLM:\System\CurrentControlSet\Control\Lsa\FipsAlgorithmPolicy -Name Enabled -Value ${{ matrix.FIPSMODE }}
- run: ./bin/otelcol-fips_windows_amd64.exe --version
id: run-otelcol
continue-on-error: true
- run: echo "FIPS enabled, started successfully"
if: matrix.FIPSMODE == '1' && steps.run-otelcol.outcome == 'success'
- run: throw "FIPS enabled, should not have failed"
if: matrix.FIPSMODE == '1' && steps.run-otelcol.outcome == 'failure'
- run: echo "FIPS disabled, failed successfully"
if: matrix.FIPSMODE == '0' && steps.run-otelcol.outcome == 'failure'
- run: throw "FIPS disabled, should have failed"
if: matrix.FIPSMODE == '0' && steps.run-otelcol.outcome == 'success'

docker-otelcol-fips:
runs-on: ${{ fromJSON('["ubuntu-20.04", "otel-arm64"]')[matrix.ARCH == 'arm64'] }}
needs: [ otelcol-fips ]
strategy:
matrix:
ARCH: [ amd64, arm64 ]
fail-fast: false
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: '**/go.sum'
- uses: actions/download-artifact@v4
with:
name: otelcol-fips-linux-${{ matrix.ARCH }}
path: ./bin
- run: make docker-otelcol SKIP_COMPILE=true
env:
FIPS: true
ARCH: ${{ matrix.ARCH }}
- name: Ensure the collector container can run with the default config
run: |
docker run -d --name otelcol-fips -e SPLUNK_ACCESS_TOKEN=fake-token -e SPLUNK_REALM=fake-realm otelcol-fips:${{ matrix.ARCH }}
sleep 30
docker logs otelcol-fips
if [ -z "$( docker ps --filter=status=running --filter=name=otelcol-fips -q )" ]; then
exit 1
fi
docker rm -f otelcol-fips
- name: Ensure the collector container can run with all included configs
run: |
for config in cmd/otelcol/fips/config/*.yaml; do
docker run -d --name otelcol-fips -e SPLUNK_ACCESS_TOKEN=fake-token -e SPLUNK_REALM=fake-realm -e SPLUNK_CONFIG=/etc/otel/collector/$(basename $config) otelcol-fips:${{ matrix.ARCH }}
sleep 30
docker logs otelcol-fips
if [ -z "$( docker ps --filter=status=running --filter=name=otelcol-fips -q )" ]; then
exit 1
fi
docker rm -f otelcol-fips
done
- run: docker save -o image.tar otelcol-fips:${{ matrix.ARCH }}
- uses: actions/upload-artifact@v4
with:
name: docker-otelcol-fips-${{ matrix.ARCH }}
path: ./image.tar

win-docker-otelcol-fips:
runs-on: windows-${{ matrix.WIN_VERSION }}
needs: [ otelcol-fips ]
strategy:
matrix:
WIN_VERSION: [ 2019, 2022 ]
fail-fast: false
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/download-artifact@v4
with:
name: otelcol-fips-windows-amd64
path: ./cmd/otelcol/fips/dist
- run: docker build --pull -t otelcol-fips:${{ matrix.WIN_VERSION }} --build-arg BASE_IMAGE=${env:BASE_IMAGE} -f .\cmd\otelcol\fips\Dockerfile.windows .\cmd\otelcol\fips
env:
BASE_IMAGE: mcr.microsoft.com/windows/servercore:ltsc${{ matrix.WIN_VERSION }}
- name: Ensure the collector container can run with the default config
shell: bash
run: |
docker run -d --name otelcol-fips -e SPLUNK_ACCESS_TOKEN=fake-token -e SPLUNK_REALM=fake-realm otelcol-fips:${{ matrix.WIN_VERSION }}
sleep 30
docker logs otelcol-fips
if [ -z "$( docker ps --filter=status=running --filter=name=otelcol-fips -q )" ]; then
exit 1
fi
docker rm -f otelcol-fips
- name: Ensure the collector container can run with all included configs
shell: bash
run: |
for config in cmd/otelcol/fips/config/*.yaml; do
docker run -d --name otelcol-fips -e SPLUNK_ACCESS_TOKEN=fake-token -e SPLUNK_REALM=fake-realm -e SPLUNK_CONFIG="C:\\ProgramData\\Splunk\\OpenTelemetry Collector\\$(basename $config)" otelcol-fips:${{ matrix.WIN_VERSION }}
sleep 30
docker logs otelcol-fips
if [ -z "$( docker ps --filter=status=running --filter=name=otelcol-fips -q )" ]; then
exit 1
fi
docker rm -f otelcol-fips
done
39 changes: 38 additions & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,40 @@ compile:
- bin/otelcol_*
- bin/migratecheckpoint_*

otelcol-fips:
image: '${DOCKER_CICD_REPO}/ci-container/golang-1.22:3.4.0'
extends:
- .trigger-filter
stage: build
needs: []
parallel:
matrix:
- GOOS: linux
GOARCH: amd64
TAG: main
- GOOS: linux
GOARCH: arm64
TAG: arm
- GOOS: windows
GOARCH: amd64
TAG: main
tags:
- $TAG
id_tokens: # http://go/gitlab-17
CI_JOB_JWT:
aud: $CICD_VAULT_ADDR
script:
- *docker-reader-role
- |
if [[ -n "${CI_COMMIT_TAG:-}" ]]; then
make otelcol-fips VERSION=${CI_COMMIT_TAG} DOCKER_REPO=${DOCKER_HUB_REPO}
else
make otelcol-fips DOCKER_REPO=${DOCKER_HUB_REPO}
fi
artifacts:
paths:
- bin/otelcol-fips_*

libsplunk:
extends: .trigger-filter
stage: build
Expand Down Expand Up @@ -437,9 +471,10 @@ sign-exe:
retry: 2
needs:
- compile
- otelcol-fips
parallel:
matrix:
- TARGET: [otelcol]
- TARGET: [otelcol, otelcol-fips]
variables:
ARTIFACT: bin/${TARGET}_windows_amd64.exe
SIGN_TYPE: WIN
Expand Down Expand Up @@ -1299,6 +1334,7 @@ github-release:
stage: github-release
dependencies:
- compile
- otelcol-fips
- libsplunk
- sign-exe
- sign-osx
Expand All @@ -1312,6 +1348,7 @@ github-release:
script:
- mkdir -p dist/assets
- cp bin/otelcol_linux_* dist/assets/
- cp bin/otelcol-fips_linux_* dist/assets/
- cp instrumentation/dist/libsplunk_*.so dist/assets/
- cp dist/signed/* dist/assets/
- |
Expand Down
68 changes: 68 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,78 @@

## Unreleased

### πŸ›‘ Breaking changes πŸ›‘

- (Splunk) Remove deprecated memory ballast extension ([#5429](https://github.com/open-telemetry/opentelemetry-collector/pull/5429))

### 🚩Deprecations 🚩

- (Splunk) Deprecate the jaegergrpc monitor ([#5428](https://github.com/signalfx/splunk-otel-collector/pull/5428))

### πŸ’‘ Enhancements πŸ’‘

- (Splunk) Initial release of standalone collector binaries for Linux (amd64/arm64) and Windows (amd64) with FIPS 140-2 support. These are experimental (alpha) binaries, and it is not suitable to use them in production environments. ([#5378](https://github.com/signalfx/splunk-otel-collector/pull/5378)):
- `otelcol-fips_linux_<amd64|arm64>`: Built with [`GOEXPERIMENT=boringcrypto`](https://go.dev/src/crypto/internal/boring/README) and [`crypto/tls/fipsonly`](https://go.dev/src/crypto/tls/fipsonly/fipsonly.go).
- `otelcol-fips_windows_amd64.exe`: Built with [`GOEXPERIMENT=cngcrypto`](https://github.com/microsoft/go/blob/microsoft/main/eng/doc/fips/README.md) and [`requirefips`](https://github.com/microsoft/go/blob/microsoft/main/eng/doc/fips/README.md#build-option-to-require-fips-mode) (the collector will panic if FIPS is not enabled on the Windows host).
- Smart Agent components are not currently supported.
- Download the binaries from the list of assets below.

## v0.110.0

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

Additionally, updates `splunk-otel-javaagent` to [`v2.8.1`](https://github.com/signalfx/splunk-otel-java/releases/tag/v2.8.1) and `jmx-metric-gatherer` to [`v1.39.0`](https://github.com/open-telemetry/opentelemetry-java-contrib/releases/tag/v1.39.0)

### πŸ›‘ Breaking changes πŸ›‘

- (Core) `processorhelper`: Update incoming/outgoing metrics to a single metric with `otel.signal` attributes. ([#11144](https://github.com/open-telemetry/opentelemetry-collector/pull/11144))
- (Core) processorhelper: Remove deprecated [Traces|Metrics|Logs]Inserted funcs ([#11151](https://github.com/open-telemetry/opentelemetry-collector/pull/11151))
- (Core) config: Mark UseLocalHostAsDefaultHostfeatureGate as stable ([#11235](https://github.com/open-telemetry/opentelemetry-collector/pull/11235))
- (Contrib) `pkg/stanza`: Move filelog.container.removeOriginalTimeField feature gate to beta. Disable the filelog.container.removeOriginalTimeField feature gate to get the old behavior. ([#33389](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/33389))
- (Contrib) `resourcedetectionprocessor`: Move processor.resourcedetection.hostCPUSteppingAsString feature gate to stable. ([#31136](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/31136))
- (Contrib) `resourcedetectionprocessor`: Remove processor.resourcedetection.hostCPUModelAndFamilyAsString feature gate. ([#29025](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/29025))


### 🚩 Deprecations 🚩

- (Core) `processorhelper`: deprecate accepted/refused/dropped metrics ([#11201](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/11201))
- (Contrib) `hostmetricsreceiver`: Set the receiver.hostmetrics.normalizeProcessCPUUtilization feature gate to stable. ([#34763](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34763))

### πŸ’‘ Enhancements πŸ’‘

- (Core) `confignet`: Mark module as Stable. ([#9801](https://github.com/open-telemetry/opentelemetry-collector/pull/9801))
- (Core) `confmap/provider/envprovider`: Support default values when env var is empty ([#5228](https://github.com/open-telemetry/opentelemetry-collector/pull/5228))
- (Core) `service/telemetry`: Mark useOtelWithSDKConfigurationForInternalTelemetry as stable ([#7532](https://github.com/open-telemetry/opentelemetry-collector/pull/7532))
- (Contrib) `processor/transform`: Add custom function to the transform processor to convert exponential histograms to explicit histograms. ([#33827](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/33827))
- (Contrib) `file_storage`: provide a new option to the user to create a directory on start ([#34939](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34939))
- (Contrib) `headersetterextension`: adding default_value config. `default_value` config item applied in case context value is empty. ([#34412](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34412))
- (Contrib) `kafkaexporter`: Add support for encoding extensions in the Kafka exporter. This change adds support for encoding extensions in the Kafka exporter. Loading extensions takes precedence over the internally supported encodings. ([#34384](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34384))
- (Contrib) `kafkareceiver`: Add support for otlp_json encoding to Kafka receiver. The payload is deserialized into OpenTelemetry traces using JSON format. This encoding allows the Kafka receiver to handle trace data in JSON format, enabling integration with systems that export traces as JSON-encoded data. ([#33627](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/33627))
- (Contrib) `pkg/ottl`: Improved JSON unmarshaling performance by 10-20% by switching dependencies. ([#35130](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35130))
- (Contrib) `pkg/ottl`: Added support for locale in the Time converter ([#32978](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/32978))
- (Contrib) `remotetapprocessor`: Origin header is no longer required for websocket connections ([#34925](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34925))
- (Contrib) `deltatorateprocessor`: Remove unnecessary data copies. ([#35165](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35165))
- (Contrib) `transformprocessor`: Remove unnecessary data copy when transform sum to/from gauge ([#35177](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35177))
- (Contrib) `sapmexporter`: Prioritize token in context when accesstokenpassthrough is enabled ([#35123](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35123))
- (Contrib) `tailsamplingprocessor`: Fix the behavior for numeric tag filters with inverse_match set to true. ([#34296](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34296))
- (Splunk) Update instruction for partial discovery ([#5402](https://github.com/signalfx/splunk-otel-collector/pull/5402))

### 🧰 Bug fixes 🧰

- (Core) `service`: Ensure process telemetry is registered when internal telemetry is configured with readers instead of an address. ([#11093](https://github.com/open-telemetry/opentelemetry-collector/pull/11093))
- (Contrib) `splunkenterprise`: Fix a flaky search related to iops metrics. ([#35081](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35081))
- (Contrib) `azuremonitorexporter`: fix issue for property endpoint is ignored when using instrumentation_key ([#33971](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/33971))
- (Contrib) `groupbytraceprocessor`: Ensure processor_groupbytrace_incomplete_releases metric has a unit. ([#35221](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35221))
- (Contrib) `deltatocumulative`: do not drop gauges and summaries. Gauges and Summaries are no longer dropped from processor output. Instead, they are passed through as-is. ([#35284](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35284))
- (Contrib) `pkg/stanza`: Do not get formatted message for Windows events without an event provider. Attempting to get the formatted message for Windows events without an event provider can result in an error being logged. This change ensures that the formatted message is not retrieved for such events. ([#35135](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35135))
- (Contrib) `signalfxexporter`: Ensure token is not sent through for event data ([#35154](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35154))
- (Contrib) `prometheusreceiver`: Fix the retrieval of scrape configurations by also considering scrape config files ([#34786](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/34786))
- (Contrib) `redactionprocessor`: Fix panic when using the redaction processor in a logs pipeline ([#35331](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35331))
- (Contrib) `exporter/splunkhec`: Fix incorrect claim that the exporter doesn't mutate data when batching is enabled. The bug lead to runtime panics when the exporter was used with the batcher enabled in a fanout scenario. ([#35306](https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/35306))
- (Splunk) Choco upgrade should preserve collector service custom env vars ([#5386](https://github.com/signalfx/splunk-otel-collector/pull/5386))
- (Splunk) `discoveryreceiver` with `splunk.continuousDiscovery` feature gate enabled: Remove redundant discovery.receiver.rule attribute ([#5403](https://github.com/signalfx/splunk-otel-collector/pull/5403))
- (Splunk) `discoveryreceiver` with `splunk.continuousDiscovery` feature gate enabled: Remove redundant resource attributes ([#5409](https://github.com/signalfx/splunk-otel-collector/pull/5409))

## v0.109.0

### πŸ›‘ Breaking changes πŸ›‘
Expand Down
Loading

0 comments on commit d66922c

Please sign in to comment.