Skip to content

Commit

Permalink
Merge branch 'main' into fix_metrics_sourcetype_annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
mstopa-splunk committed Jan 6, 2025
2 parents ffa3a20 + b49ef63 commit 861eeb3
Show file tree
Hide file tree
Showing 425 changed files with 37,443 additions and 14,155 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement
change_type: bug_fix
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: agent
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Added `fsyncFlag` configuration to allow users to enable fsync on the filestorage.
note: Scrape FS metrics from one host disk mounted to the root to avoid scraping errors since the collector likely doesn't have access to other mounts.
# One or more tracking issues related to the change
issues: [1425]
issues: [1569]
8 changes: 4 additions & 4 deletions .chloggen/fixexplicittokenta.yaml → .chloggen/fips.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: bug_fix
change_type: enhancement
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: targetAllocator
component: collector
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Fix the name of the service account token given when featureGates.explicitMountServiceAccountToken is true
note: Document the possible use of a FIPS-140 compliant image
# One or more tracking issues related to the change
issues: [1427]
issues: [1582]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: 'enhancement'
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: clusterReceiver
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Configure k8s attributes processor for cluster receiver to ingest events into index defined in namespace annotation
# One or more tracking issues related to the change
issues: [1481]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@ change_type: enhancement
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: agent
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Add a feature gate `useControlPlaneMetricsHistogramData`
note: Make it so the default tolerations used to deploy the agent collector account for k8s distribution
# One or more tracking issues related to the change
issues: [1372]
issues: [1562]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext: |
This feature gate allows to gather control plane metrics and send them as histogram data to Observability Cloud.
This is an experimental feature under heavy development.
subtext: OpenShift infra nodes and AKS system nodes will now be monitored by the agent by default
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: breaking
change_type: enhancement
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: operator
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Operator Helm values previously under `.Values.operator.instrumentation.spec.*` have been moved to `.Values.instrumentation.*`
note: Bump dotnet to v1.8.0 in helm-charts/splunk-otel-collector/values.yaml
# One or more tracking issues related to the change
issues: [1436]
issues: [1538]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext: If you use custom values under `.Values.operator.instrumentation.spec.*` please review the [upgrade guidelines](https://github.com/signalfx/splunk-otel-collector-chart/blob/main/UPGRADING.md#01055-01080)
subtext:
12 changes: 12 additions & 0 deletions .chloggen/update-java.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: operator
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Bump java to v2.10.0 in helm-charts/splunk-otel-collector/values.yaml
# One or more tracking issues related to the change
issues: [1551]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:
12 changes: 12 additions & 0 deletions .chloggen/update-nodejs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: operator
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Bump nodejs to v2.15.0 in helm-charts/splunk-otel-collector/values.yaml
# One or more tracking issues related to the change
issues: [1558]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:
12 changes: 12 additions & 0 deletions .chloggen/update-service-telemetry-endpoint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement
# The name of the component, or a single word describing the area of concern, (e.g. agent, clusterReceiver, gateway, operator, chart, other)
component: agent, clusterReceiver, gateway
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Update config for scraping internal metrics to use new config interface and loopback address.
# One or more tracking issues related to the change
issues: [1573]
# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext: "This also drops redundant attributes reported with the internal metrics: `net.host.name` and `server.address`"
2 changes: 1 addition & 1 deletion .github/workflows/cla.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,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.1
uses: cla-assistant/github-action@v2.6.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PERSONAL_ACCESS_TOKEN: ${{ secrets.PAT_CLATOOL }}
Expand Down
11 changes: 10 additions & 1 deletion .github/workflows/functional_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
functional-test:
name: Kubernetes ${{ matrix.kubernetes_version }} ${{ matrix.container_runtime }}
name: K8s ${{ matrix.kubernetes_version }} ${{ matrix.container_runtime }}, Splunk ${{ matrix.splunk_version }}
runs-on: ubuntu-20.04
strategy:
fail-fast: false
Expand All @@ -24,6 +24,9 @@ jobs:
- "docker"
- "containerd"
- "cri-o"
splunk_version:
- 9.3.0
- 8.2.9
env:
CI_SPLUNK_PORT: 8089
CI_SPLUNK_USERNAME: admin
Expand All @@ -33,6 +36,7 @@ jobs:
CI_INDEX_METRICS: ci_metrics
CONTAINER_RUNTIME: ${{ matrix.container_runtime }}
KUBERNETES_VERSION: ${{ matrix.kubernetes_version }}
SPLUNK_VERSION: ${{ matrix.splunk_version }}
MINIKUBE_VERSION: latest

steps:
Expand Down Expand Up @@ -70,6 +74,11 @@ jobs:
until kubectl -n default get serviceaccount default -o name; do
sleep 1;
done
# set splunk version, hec_token, splunk password in k8s-splunk.yaml file
sed -i "s/splunk:9.3.0/splunk:${SPLUNK_VERSION}/g" ci_scripts/k8s-splunk.yml
sed -i "s/value: helloworld/value: ${CI_SPLUNK_PASSWORD}/g" ci_scripts/k8s-splunk.yml
sed -i "s/value: 00000000-0000-0000-0000-0000000000000/value: ${CI_SPLUNK_HEC_TOKEN}/g" ci_scripts/k8s-splunk.yml
cat ci_scripts/k8s-splunk.yml
# Install Splunk on minikube
kubectl apply -f ci_scripts/k8s-splunk.yml
# Wait until splunk is ready
Expand Down
89 changes: 75 additions & 14 deletions .github/workflows/functional_test_v2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,12 @@ on:
branches: [ main ]
workflow_dispatch:
inputs:
UPDATE_EXPECTED_RESULTS:
description: 'Set this to true to update expected results and collect updated test output as a Github workflow artifact.'
UPLOAD_UPDATED_EXPECTED_RESULTS:
description: 'Set this to true to upload updated golden file expected results and upload these results as a Github workflow artifact.'
required: false
default: false
UPLOAD_KUBERNETES_DEBUG_INFO:
description: 'Set this to true to collect the debug info of the k8s cluster and upload this info as a Github workflow artifact.'
required: false
default: false

Expand All @@ -20,6 +24,8 @@ jobs:
env:
KUBECONFIG: /tmp/kube-config-splunk-otel-collector-chart-functional-testing
KUBE_TEST_ENV: kind
UPLOAD_UPDATED_EXPECTED_RESULTS: ${{ github.event.inputs.UPLOAD_UPDATED_EXPECTED_RESULTS || 'false' }}
UPLOAD_KUBERNETES_DEBUG_INFO: ${{ github.event.inputs.UPLOAD_KUBERNETES_DEBUG_INFO || 'false' }}
strategy:
fail-fast: false
matrix:
Expand All @@ -36,6 +42,7 @@ jobs:
test-job:
- functional
- histogram
- configuration_switching
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -53,7 +60,7 @@ jobs:
~/go/pkg/mod
key: go-cache-${{ runner.os }}-${{ hashFiles('**/go.sum') }}
- name: Create kind cluster
uses: helm/kind-action@v1.10.0
uses: helm/kind-action@v1.11.0
with:
node_image: kindest/node:${{ matrix.k8s-version }}
kubectl_version: ${{ matrix.k8s-version }}
Expand All @@ -69,14 +76,28 @@ jobs:
run: |
make cert-manager
- name: run functional tests
id: run-functional-tests
env:
K8S_VERSION: ${{ matrix.k8s-version }}
UPDATE_EXPECTED_RESULTS: ${{ github.event.inputs.UPDATE_EXPECTED_RESULTS || 'false' }}
run: |
cd functional_tests
TEARDOWN_BEFORE_SETUP=true UPDATE_EXPECTED_RESULTS=${{ env.UPDATE_EXPECTED_RESULTS }} go test -v -tags ${{ matrix.test-job }}
- name: 'Upload test results'
if: failure() && env.UPDATE_EXPECTED_RESULTS == 'true'
TEARDOWN_BEFORE_SETUP=true UPDATE_EXPECTED_RESULTS=${{ env.UPLOAD_UPDATED_EXPECTED_RESULTS }} go test -v -tags ${{ matrix.test-job }}
- name: Collect Kubernetes Cluster debug info on failure
if: always() && (steps.run-functional-tests.outcome == 'failure' || env.UPLOAD_KUBERNETES_DEBUG_INFO == 'true')
id: collect-debug-info
run: |
echo "Functional tests failed. Collecting debug info for current state of the Kubernetes cluster..."
cd tools
./splunk_kubernetes_debug_info.sh
- name: Upload Kubernetes Cluster debug info
if: always() && (steps.run-functional-tests.outcome == 'failure' || env.UPLOAD_KUBERNETES_DEBUG_INFO == 'true')
uses: actions/upload-artifact@v4
with:
name: k8s-debug-info-${{ matrix.test-job }}-${{ matrix.k8s-version }}
path: tools/splunk_kubernetes_debug_info_*
retention-days: 5
- name: Upload test results
if: always() && env.UPLOAD_UPDATED_EXPECTED_RESULTS == 'true'
uses: actions/upload-artifact@v4
with:
name: functional_tests-${{ matrix.test-job }}-${{ matrix.k8s-version }}
Expand Down Expand Up @@ -228,14 +249,14 @@ jobs:
~/go/bin
~/go/pkg/mod
key: go-cache-${{ runner.os }}-${{ hashFiles('**/go.sum') }}
- uses: 'google-github-actions/[email protected].5'
- uses: 'google-github-actions/[email protected].7'
with:
project_id: ${{ secrets.GKE_PROJECT }}
credentials_json: ${{ secrets.GKE_SA_KEY }}
- uses: google-github-actions/[email protected].1
- uses: google-github-actions/[email protected].2
with:
project_id: ${{ secrets.GKE_PROJECT }}
- uses: google-github-actions/get-gke-credentials@v2.2.1
- uses: google-github-actions/get-gke-credentials@v2.3.0
with:
cluster_name: ${{ secrets.GKE_AUTOPILOT_CLUSTER }}
location: ${{ secrets.GKE_REGION }}
Expand Down Expand Up @@ -291,14 +312,14 @@ jobs:
~/go/bin
~/go/pkg/mod
key: go-cache-${{ runner.os }}-${{ hashFiles('**/go.sum') }}
- uses: 'google-github-actions/[email protected].5'
- uses: 'google-github-actions/[email protected].7'
with:
project_id: ${{ secrets.GKE_PROJECT }}
credentials_json: ${{ secrets.GKE_SA_KEY }}
- uses: google-github-actions/[email protected].1
- uses: google-github-actions/[email protected].2
with:
project_id: ${{ secrets.GKE_PROJECT }}
- uses: google-github-actions/get-gke-credentials@v2.2.1
- uses: google-github-actions/get-gke-credentials@v2.3.0
with:
cluster_name: ${{ secrets.GKE_AUTOPILOT_CLUSTER }}
location: ${{ secrets.GKE_REGION }}
Expand Down Expand Up @@ -347,7 +368,7 @@ jobs:
uses: azure/[email protected]
with:
kubelogin-version: "v0.0.24"
- uses: azure/login@v2.1.1
- uses: azure/login@v2.2.0
with:
creds: ${{ secrets.AZURE_CREDENTIALS }}
- uses: azure/aks-set-context@v4
Expand All @@ -365,3 +386,43 @@ jobs:
run: |
cd functional_tests
TEARDOWN_BEFORE_SETUP=true go test -v -tags functional
gce-autopilot-test:
name: Test helm install in GCE (kops) - credentials needed
needs: kubernetes-test
if: github.event.pull_request.head.repo.full_name == github.repository
concurrency:
group: gce-access
env:
KUBE_TEST_ENV: gce
SKIP_TESTS: "true"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ~1.21.8
cache: false
- name: Cache Go
id: go-cache
timeout-minutes: 5
uses: actions/cache@v4
with:
path: |
~/go/bin
~/go/pkg/mod
key: go-cache-${{ runner.os }}-${{ hashFiles('**/go.sum') }}
- name: Update dependencies
run: |
make dep-update
- name: Set kubeconfig
run: echo "$GCE_KUBECONFIG" > /tmp/kubeconfig
env:
GCE_KUBECONFIG: ${{ secrets.GCE_KUBECONFIG }}
- name: run functional tests
env:
HOST_ENDPOINT: 0.0.0.0
KUBECONFIG: /tmp/kubeconfig
run: |
cd functional_tests
TEARDOWN_BEFORE_SETUP=true go test -v -tags functional
2 changes: 1 addition & 1 deletion .github/workflows/helm-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
make unittest
- name: Create kind cluster
uses: helm/kind-action@v1.10.0
uses: helm/kind-action@v1.11.0
# Only build a kind cluster if there are chart changes to test.
if: steps.list-changed.outputs.changed == 'true'

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/migration_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
~/go/pkg/mod
key: go-cache-${{ runner.os }}-${{ hashFiles('**/go.sum') }}
- name: Create kind cluster
uses: helm/kind-action@v1.10.0
uses: helm/kind-action@v1.11.0
with:
node_image: kindest/node:${{ matrix.k8s-version }}
kubectl_version: ${{ matrix.k8s-version }}
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.idea
*.iml
.DS_Store
*splunk_kubernetes_debug_info_*

# Helm
**/charts/*.tgz
Expand Down
Loading

0 comments on commit 861eeb3

Please sign in to comment.