Skip to content

Commit 151a8c9

Browse files
Remove compatibility with inception-health/otel-upload-test-artifact-action (#39)
1 parent 3d51c7a commit 151a8c9

32 files changed

+27016
-47147
lines changed

.github/workflows/axiom.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
steps:
1414
- uses: actions/checkout@v4
1515
- name: Export workflow to Axiom
16-
uses: corentinmusard/otel-cicd-action@v1
16+
uses: corentinmusard/otel-cicd-action@v2
1717
with:
1818
otlpEndpoint: https://api.axiom.co/v1/traces
1919
# Example value for AXIOM_OTLP_HEADERS:

.github/workflows/build.yml

+1-9
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,6 @@ jobs:
3939
run: npm ci
4040
- name: run tests
4141
run: npm run test:ci
42-
- uses: inception-health/otel-upload-test-artifact-action@v1
43-
if: always()
44-
with:
45-
jobName: "tests (${{ matrix.os }})"
46-
stepName: "run tests"
47-
path: "junit.xml"
48-
type: "junit"
49-
githubToken: ${{ secrets.GITHUB_TOKEN }}
5042
otel-cicd:
5143
needs: [tests, build]
5244
if: always()
@@ -60,4 +52,4 @@ jobs:
6052
otlpHeaders: "test"
6153
githubToken: ${{ secrets.GITHUB_TOKEN }}
6254
env:
63-
OTEL_CONSOLE_ONLY: "true"
55+
OTEL_CONSOLE_ONLY: "true" # Internal flag used to disable sending data to the collector

.github/workflows/dash0.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
steps:
1414
- uses: actions/checkout@v4
1515
- name: Export workflow to Dash0
16-
uses: corentinmusard/otel-cicd-action@v1
16+
uses: corentinmusard/otel-cicd-action@v2
1717
with:
1818
otlpEndpoint: grpc://ingress.eu-west-1.aws.dash0.com:4317
1919
# See https://www.dash0.com/documentation/dash0/get-started/sending-data-to-dash0

.github/workflows/honeycomb.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
steps:
1414
- uses: actions/checkout@v4
1515
- name: Export workflow to Honeycomb
16-
uses: corentinmusard/otel-cicd-action@v1
16+
uses: corentinmusard/otel-cicd-action@v2
1717
with:
1818
otlpEndpoint: grpc://api.honeycomb.io:443/
1919
# Example value for HONEYCOMB_OTLP_HEADERS:

.github/workflows/newrelic.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
steps:
1414
- uses: actions/checkout@v4
1515
- name: Export workflow to New Relic
16-
uses: corentinmusard/otel-cicd-action@v1
16+
uses: corentinmusard/otel-cicd-action@v2
1717
with:
1818
otlpEndpoint: grpc://otlp.eu01.nr-data.net
1919
# Example value for NEWRELIC_OTLP_HEADERS:

.github/workflows/private.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
types: [completed]
99

1010
jobs:
11-
otel-export-axiom:
11+
otel-export-private:
1212
runs-on: ubuntu-latest
1313
# Permissions can be set on a per-job basis or at the top level
1414
permissions:
@@ -18,7 +18,7 @@ jobs:
1818
steps:
1919
- uses: actions/checkout@v4
2020
- name: Export workflow
21-
uses: corentinmusard/otel-cicd-action@v1
21+
uses: corentinmusard/otel-cicd-action@v2
2222
with:
2323
otlpEndpoint: "CHANGE_ME"
2424
otlpHeaders: "CHANGE_ME"

.gitignore

+1-117
Original file line numberDiff line numberDiff line change
@@ -1,125 +1,9 @@
1-
# Logs
2-
logs
3-
npm-debug.log*
4-
yarn-debug.log*
5-
yarn-error.log*
6-
lerna-debug.log*
7-
8-
# Diagnostic reports (https://nodejs.org/api/report.html)
9-
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
10-
11-
# Runtime data
12-
pids
13-
*.pid
14-
*.seed
15-
*.pid.lock
16-
17-
# Directory for instrumented libs generated by jscoverage/JSCover
18-
lib-cov
19-
20-
# Coverage directory used by tools like istanbul
1+
# Coverage directory used by istanbul
212
coverage
22-
*.lcov
23-
24-
# nyc test coverage
25-
.nyc_output
26-
27-
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
28-
.grunt
29-
30-
# Bower dependency directory (https://bower.io/)
31-
bower_components
32-
33-
# node-waf configuration
34-
.lock-wscript
35-
36-
# Compiled binary addons (https://nodejs.org/api/addons.html)
37-
build/Release
38-
39-
# Dependency directories
40-
node_modules/
41-
jspm_packages/
42-
43-
# TypeScript v1 declaration files
44-
typings/
45-
46-
# TypeScript cache
47-
*.tsbuildinfo
48-
49-
# Optional npm cache directory
50-
.npm
51-
52-
# Optional eslint cache
53-
.eslintcache
54-
55-
# Microbundle cache
56-
.rpt2_cache/
57-
.rts2_cache_cjs/
58-
.rts2_cache_es/
59-
.rts2_cache_umd/
60-
61-
# Optional REPL history
62-
.node_repl_history
63-
64-
# Output of 'npm pack'
65-
*.tgz
66-
67-
# Yarn Integrity file
68-
.yarn-integrity
693

704
# dotenv environment variables file
715
.env
726
.env.test
737

74-
# parcel-bundler cache (https://parceljs.org/)
75-
.cache
76-
77-
# Next.js build output
78-
.next
79-
80-
# Nuxt.js build / generate output
81-
.nuxt
82-
lib
83-
84-
# Gatsby files
85-
.cache/
86-
# Comment in the public line in if your project uses Gatsby and *not* Next.js
87-
# https://nextjs.org/blog/next-9-1#public-directory-support
88-
# public
89-
90-
# vuepress build output
91-
.vuepress/dist
92-
93-
# Serverless directories
94-
.serverless/
95-
96-
# FuseBox cache
97-
.fusebox/
98-
99-
# DynamoDB Local files
100-
.dynamodb/
101-
102-
# TernJS port file
103-
.tern-port
104-
105-
# Taskfile
106-
.task
107-
1088
.DS_Store
109-
110-
docker/
111-
112-
!./dist/index.js
113-
./src/*.js
114-
!jest.config.js
115-
!.dependency-cruiser.js
116-
*.d.ts
1179
node_modules
118-
.node-version
119-
120-
# CDK asset staging directory
121-
.cdk.staging
122-
cdk.out
123-
124-
# Test Reports
125-
junit.xml

CHANGELOG.md

+14-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [2.0.0] - 2025-01-04
11+
12+
### ⚠ BREAKING CHANGES
13+
14+
- Removed compatibility with [inception-health/otel-upload-test-artifact-action](https://github.com/inception-health/otel-upload-test-artifact-action) action. It is based on `@actions/artifact` prior to `v2` which is deprecated since June 2024 and will be removed in [January 30th, 2025](https://github.blog/changelog/2024-04-16-deprecation-notice-v3-of-the-artifact-actions/). If you were using this action, please open an issue to discuss your use case.
15+
- Removed `github.author_name` attribute, use `github.head_commit.author.name` instead
16+
- Removed `github.author_email` attribute, use `github.head_commit.author.email` instead
17+
18+
### Changed
19+
20+
- Changed licence under my name (still MIT)
21+
1022
## [1.13.2] - 2025-01-04
1123

1224
### Fixed
@@ -123,7 +135,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
123135
- Support for `https` endpoints (proto over http).
124136
- Update to node 20.x
125137

126-
[unreleased]: https://github.com/corentinmusard/otel-cicd-action/compare/v1.13.2...HEAD
138+
[unreleased]: https://github.com/corentinmusard/otel-cicd-action/compare/v2.0.0...HEAD
139+
[2.0.0]: https://github.com/corentinmusard/otel-cicd-action/compare/v1.13.2...v2.0.0
127140
[1.13.2]: https://github.com/corentinmusard/otel-cicd-action/compare/v1.13.1...v1.13.2
128141
[1.13.1]: https://github.com/corentinmusard/otel-cicd-action/compare/v1.13.0...v1.13.1
129142
[1.13.0]: https://github.com/corentinmusard/otel-cicd-action/compare/v1.12.1...v1.13.0

README.md

+5-67
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ This action exports Github CI/CD workflows to any endpoint compatible with OpenT
77

88
This is a fork of [otel-export-trace-action](https://github.com/inception-health/otel-export-trace-action) with more features and better support.
99

10+
Compliant with OpenTelemetry [CICD semconv](https://opentelemetry.io/docs/specs/semconv/attributes-registry/cicd/).
11+
Look at [Sample OpenTelemetry Output](./src/__assets__/output.txt) for the list of attributes and their values.
12+
1013
![Example](./docs/honeycomb-example.png)
1114

1215
## Usage
@@ -40,7 +43,7 @@ jobs:
4043
otel-cicd-actions:
4144
runs-on: ubuntu-latest
4245
steps:
43-
- uses: corentinmusard/otel-cicd-action@v1
46+
- uses: corentinmusard/otel-cicd-action@v2
4447
with:
4548
otlpEndpoint: grpc://api.honeycomb.io:443/
4649
otlpHeaders: ${{ secrets.OTLP_HEADERS }}
@@ -61,7 +64,7 @@ jobs:
6164
needs: [build] # must run when all jobs are completed
6265
steps:
6366
- name: Export workflow
64-
uses: corentinmusard/otel-cicd-action@v1
67+
uses: corentinmusard/otel-cicd-action@v2
6568
with:
6669
otlpEndpoint: grpc://api.honeycomb.io:443/
6770
otlpHeaders: ${{ secrets.OTLP_HEADERS }}
@@ -107,71 +110,6 @@ permissions:
107110
| ------- | ------------------------------------------- |
108111
| traceId | The OpenTelemetry Trace ID of the root span |
109112

110-
Look at [Sample OpenTelemetry Output](./src/__assets__/output.txt) for the list of attributes and their values.
111-
112-
#### Honeycomb Example Trace
113-
114-
![HoneyComb Example](./docs/honeycomb-example.png)
115-
116-
_with JUnit traces_
117-
![HoneyComb Junit Example](./docs/honeycomb-junit-example.png)
118-
119-
## With Junit Tracing
120-
121-
Combined with [OpenTelemetry Upload Trace Artifact](https://github.com/marketplace/actions/opentelemetry-upload-trace-artifact) this action will Download the OTLP Trace Log Artifact uploaded from the Workflow Run and export it.
122-
123-
**pr-workflow.yml**
124-
125-
```yaml
126-
name: "PR check"
127-
128-
on:
129-
pull_request:
130-
branches: [main]
131-
132-
jobs:
133-
build-and-test:
134-
runs-on: ubuntu-latest
135-
steps:
136-
- uses: actions/checkout@v2
137-
- uses: actions/setup-node@v2
138-
- name: Install Dependencies
139-
run: npm ci --ignore-scripts
140-
- name: run tests
141-
run: npm run test:ci
142-
- uses: inception-health/otel-upload-test-artifact-action@v1
143-
if: always()
144-
with:
145-
jobName: "build-and-test"
146-
stepName: "run tests"
147-
path: "junit.xml"
148-
type: "junit"
149-
githubToken: ${{ secrets.GITHUB_TOKEN }}
150-
```
151-
152-
**otel-cicd.yml**
153-
154-
```yaml
155-
name: OpenTelemetry Export Traces
156-
157-
on:
158-
workflow_run:
159-
workflows: ["PR check"]
160-
types: [completed]
161-
162-
jobs:
163-
otel-cicd-action:
164-
runs-on: ubuntu-latest
165-
steps:
166-
- name: Export Workflow Traces
167-
uses: corentinmusard/otel-cicd-action@v1
168-
with:
169-
otlpEndpoint: grpc://api.honeycomb.io:443/
170-
otlpHeaders: ${{ secrets.OTLP_HEADERS }}
171-
githubToken: ${{ secrets.GITHUB_TOKEN }}
172-
runId: ${{ github.event.workflow_run.id }}
173-
```
174-
175113
[ci-img]: https://github.com/corentinmusard/otel-cicd-action/actions/workflows/build.yml/badge.svg?branch=main
176114
[ci]: https://github.com/corentinmusard/otel-cicd-action/actions/workflows/build.yml?query=branch%3Amain
177115
[license-img]: https://img.shields.io/github/license/corentinmusard/otel-cicd-action

biome.json

-3
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,6 @@
1010
"complexity": {
1111
"useLiteralKeys": "off",
1212
"noExcessiveCognitiveComplexity": "info"
13-
},
14-
"performance": {
15-
"noAccumulatingSpread": "off"
1613
}
1714
}
1815
},

0 commit comments

Comments
 (0)