Skip to content

Commit 20628f0

Browse files
committed
Merge branch 'main' into tm-dep-check-with-knip
2 parents 793a566 + 836ae2d commit 20628f0

File tree

80 files changed

+4207
-695
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+4207
-695
lines changed

.github/component-label-map.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,14 @@ pkg:sql-common:
274274
- changed-files:
275275
- any-glob-to-any-file:
276276
- packages/opentelemetry-sql-common/**
277+
pkg:propagator-aws-xray:
278+
- changed-files:
279+
- any-glob-to-any-file:
280+
- propagators/propagator-aws-xray/**
281+
pkg:propagator-aws-xray-lambda:
282+
- changed-files:
283+
- any-glob-to-any-file:
284+
- propagators/propagator-aws-xray-lambda/**
277285
pkg-status:unmaintained:
278286
- changed-files:
279287
- any-glob-to-any-file:
@@ -296,3 +304,5 @@ pkg-status:unmaintained:
296304
- plugins/node/opentelemetry-instrumentation-restify/**
297305
- plugins/node/opentelemetry-instrumentation-router/**
298306
- propagators/opentelemetry-propagator-ot-trace/**
307+
- propagators/propagator-aws-xray/**
308+
- propagators/propagator-aws-xray-lambda/**

.github/component_owners.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,10 @@ components:
145145
- kirrg001
146146
propagators/opentelemetry-propagator-ot-trace: []
147147
# Unmaintained
148+
propagators/propagator-aws-xray: [ ]
149+
# Unmaintained
150+
propagators/propagator-aws-xray-lambda: [ ]
151+
# Unmaintained
148152

149153
ignored-authors:
150154
- renovate-bot

.github/workflows/lint.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,3 @@ jobs:
1919
- name: Lint
2020
run: |
2121
npm run lint
22-
npm run lint:markdown
23-
npm run lint:readme

.release-please-manifest.json

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
"detectors/node/opentelemetry-resource-detector-alibaba-cloud": "0.29.3",
33
"detectors/node/opentelemetry-resource-detector-aws": "1.6.2",
44
"detectors/node/opentelemetry-resource-detector-azure": "0.2.11",
5-
"detectors/node/opentelemetry-resource-detector-container": "0.4.3",
5+
"detectors/node/opentelemetry-resource-detector-container": "0.4.4",
66
"detectors/node/opentelemetry-resource-detector-gcp": "0.29.12",
77
"detectors/node/opentelemetry-resource-detector-github": "0.29.0",
88
"detectors/node/opentelemetry-resource-detector-instana": "0.13.0",
99
"metapackages/auto-configuration-propagators": "0.3.1",
10-
"metapackages/auto-instrumentations-node": "0.50.2",
10+
"metapackages/auto-instrumentations-node": "0.51.0",
1111
"metapackages/auto-instrumentations-web": "0.41.0",
1212
"packages/baggage-span-processor": "0.3.1",
1313
"packages/opentelemetry-host-metrics": "0.35.4",
@@ -48,7 +48,7 @@
4848
"plugins/node/opentelemetry-instrumentation-mysql2": "0.41.0",
4949
"plugins/node/opentelemetry-instrumentation-nestjs-core": "0.40.0",
5050
"plugins/node/opentelemetry-instrumentation-net": "0.39.0",
51-
"plugins/node/opentelemetry-instrumentation-pg": "0.45.1",
51+
"plugins/node/opentelemetry-instrumentation-pg": "0.46.0",
5252
"plugins/node/opentelemetry-instrumentation-pino": "0.42.0",
5353
"plugins/node/opentelemetry-instrumentation-redis": "0.42.0",
5454
"plugins/node/opentelemetry-instrumentation-redis-4": "0.42.1",
@@ -60,5 +60,7 @@
6060
"plugins/web/opentelemetry-instrumentation-user-interaction": "0.40.0",
6161
"plugins/web/opentelemetry-plugin-react-load": "0.31.0",
6262
"propagators/opentelemetry-propagator-instana": "0.3.2",
63-
"propagators/opentelemetry-propagator-ot-trace": "0.27.2"
63+
"propagators/opentelemetry-propagator-ot-trace": "0.27.2",
64+
"propagators/propagator-aws-xray": "1.26.0",
65+
"propagators/propagator-aws-xray-lambda": "0.53.0"
6466
}

detectors/node/opentelemetry-resource-detector-container/CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
# Changelog
22

3+
## [0.4.4](https://github.com/open-telemetry/opentelemetry-js-contrib/compare/resource-detector-container-v0.4.3...resource-detector-container-v0.4.4) (2024-10-16)
4+
5+
6+
### Bug Fixes
7+
8+
* **detector-container:** properly detect container ID when using Podman ([#2448](https://github.com/open-telemetry/opentelemetry-js-contrib/issues/2448)) ([ad560df](https://github.com/open-telemetry/opentelemetry-js-contrib/commit/ad560dfc5f662d418a74b0b197b3f48e4ae002d0))
9+
310
## [0.4.3](https://github.com/open-telemetry/opentelemetry-js-contrib/compare/resource-detector-container-v0.4.2...resource-detector-container-v0.4.3) (2024-10-10)
411

512

detectors/node/opentelemetry-resource-detector-container/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@opentelemetry/resource-detector-container",
3-
"version": "0.4.3",
3+
"version": "0.4.4",
44
"description": "Opentelemetry resource detector to get container resource attributes",
55
"main": "build/src/index.js",
66
"types": "build/src/index.d.ts",

detectors/node/opentelemetry-resource-detector-container/src/detectors/ContainerDetector.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export class ContainerDetector implements DetectorSync {
3535
readonly DEFAULT_CGROUP_V2_PATH = '/proc/self/mountinfo';
3636
readonly UTF8_UNICODE = 'utf8';
3737
readonly HOSTNAME = 'hostname';
38-
readonly MARKING_PREFIX = 'containers';
38+
readonly MARKING_PREFIX = ['containers', 'overlay-containers'];
3939
readonly CRIO = 'crio-';
4040
readonly CRI_CONTAINERD = 'cri-containerd-';
4141
readonly DOCKER = 'docker-';
@@ -105,7 +105,7 @@ export class ContainerDetector implements DetectorSync {
105105
const strArray = str?.split('/') ?? [];
106106
for (let i = 0; i < strArray.length - 1; i++) {
107107
if (
108-
strArray[i] === this.MARKING_PREFIX &&
108+
this.MARKING_PREFIX.includes(strArray[i]) &&
109109
strArray[i + 1]?.length === this.CONTAINER_ID_LENGTH
110110
) {
111111
return strArray[i + 1];

detectors/node/opentelemetry-resource-detector-container/src/detectors/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export const DEFAULT_CGROUP_V1_PATH = '/proc/self/cgroup';
1818
export const DEFAULT_CGROUP_V2_PATH = '/proc/self/mountinfo';
1919
export const UTF8_UNICODE = 'utf8';
2020
export const HOSTNAME = 'hostname';
21-
export const MARKING_PREFIX = 'containers';
21+
export const MARKING_PREFIX = ['containers', 'overlay-containers'];
2222
export const CRIO = 'crio-';
2323
export const CRI_CONTAINERD = 'cri-containerd-';
2424
export const DOCKER = 'docker-';

detectors/node/opentelemetry-resource-detector-container/test/ContainerDetector.test.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ describe('ContainerDetector', () => {
3232
const correctCgroupV2Data = `containers/tmhdefghijklmnopqrstuvwxyzafgrefghiugkmnopqrstuvwxyzabcdefghijkl/hostname
3333
fhkjdshgfhsdfjhdsfkjhfkdshkjhfd/host
3434
sahfhfjkhjhfhjdhfjkdhfkjdhfjkhhdsjfhdfhjdhfkj/somethingelse`;
35+
const correctCgroupV2PodmanData =
36+
'4245 4237 0:94 /containers/overlay-containers/4e9dc37d00ebd2daea029d84bb37764ce12d746a6f3a33c5969cee15c4fc4418/userdata/hostname /etc/hostname rw - tmpfs tmpfs rw';
3537

3638
const wrongCgroupV2Data =
3739
'bcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklm/wrongkeyword';
@@ -85,6 +87,22 @@ describe('ContainerDetector', () => {
8587
});
8688
});
8789

90+
it('should return a resource with container ID with a valid container ID present for v2 (Podman)', async () => {
91+
readStub = sinon.stub(ContainerDetector, 'readFileAsync' as any);
92+
93+
readStub.onFirstCall().resolves('');
94+
readStub.onSecondCall().resolves(correctCgroupV2PodmanData);
95+
96+
const resource = containerDetector.detect();
97+
await resource.waitForAsyncAttributes?.();
98+
sinon.assert.calledTwice(readStub);
99+
100+
assert.ok(resource);
101+
assertContainerResource(resource, {
102+
id: '4e9dc37d00ebd2daea029d84bb37764ce12d746a6f3a33c5969cee15c4fc4418',
103+
});
104+
});
105+
88106
it('should return a empty resource with failed hostname check for v2', async () => {
89107
readStub = sinon.stub(ContainerDetector, 'readFileAsync' as any);
90108

metapackages/auto-instrumentations-node/CHANGELOG.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
11
# Changelog
22

3+
## [0.51.0](https://github.com/open-telemetry/opentelemetry-js-contrib/compare/auto-instrumentations-node-v0.50.2...auto-instrumentations-node-v0.51.0) (2024-10-16)
4+
5+
6+
### ⚠ BREAKING CHANGES
7+
8+
* **auto-instrumentations-node:** disable @opentelemetry/instrumentation-fs by default ([#2467](https://github.com/open-telemetry/opentelemetry-js-contrib/issues/2467))
9+
10+
### Features
11+
12+
* **auto-instrumentations-node:** disable @opentelemetry/instrumentation-fs by default ([#2467](https://github.com/open-telemetry/opentelemetry-js-contrib/issues/2467)) ([a558044](https://github.com/open-telemetry/opentelemetry-js-contrib/commit/a55804415d39c751a3f5f58c00cf27747821302f))
13+
14+
15+
### Dependencies
16+
17+
* The following workspace dependencies were updated
18+
* dependencies
19+
* @opentelemetry/instrumentation-pg bumped from ^0.45.1 to ^0.46.0
20+
* @opentelemetry/resource-detector-container bumped from ^0.4.3 to ^0.4.4
21+
322
## [0.50.2](https://github.com/open-telemetry/opentelemetry-js-contrib/compare/auto-instrumentations-node-v0.50.1...auto-instrumentations-node-v0.50.2) (2024-10-10)
423

524

0 commit comments

Comments
 (0)