-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add temporal metrics and tracing docs for Signoz #1208
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
0b94a56
to
2d69743
Compare
2d69743
to
7504528
Compare
7504528
to
120c5c6
Compare
120c5c6
to
706b390
Compare
I will be reviewing this when ready |
@Creator54 when will this be ready for review? |
153dfb6
to
1118fe5
Compare
af79a49
to
ccc4e84
Compare
ccc4e84
to
1afe14e
Compare
1afe14e
to
230ffbc
Compare
230ffbc
to
4d752b3
Compare
this is ready for review, please check and let me know if any changes required. |
@ankitnayan this PR is ready for review - Preview here |
@Creator54 which guide/doc did you follow to create code structure at https://github.com/Creator54/temporal-typescript-demo-app/tree/otel/src/config? |
I started with the Temporal TypeScript samples and the observability docs, but found them challenging to follow. So decided to port the temporal-java project. |
The tracing docs has references to metrics code too. So, the steps mentioned in the traces docs won't run independently. IMO we should build single docs for setup of Metrics + Traces + Logs |
the code at Apart from above, the code structure at the |
the outbound and internal interceptors seem missing as they are present in the official example https://github.com/temporalio/samples-typescript/blob/main/interceptors-opentelemetry/src/workflows.ts#L19 |
I see data hardcoded in the sample app. Why is this so? |
Every metric datapoint is being created periodically in a hardcoded way? https://github.com/Creator54/temporal-typescript-demo-app/blob/otel/src/config/temporalConfig.ts#L124-L132 |
It was for visualization purposes, so most panels have some data to visualize without waiting for all the flows. |
|
telemetryOptions: { | ||
metrics: { | ||
otel: { | ||
url: process.env.OTEL_EXPORTER_OTLP_ENDPOINT || 'http://127.0.0.1:4317', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing auth headers
headers: {
'signoz-ingestion-key': xxx,
},
metrics: { | ||
otel: { | ||
url: process.env.OTEL_EXPORTER_OTLP_ENDPOINT || 'http://127.0.0.1:4317', | ||
metricsExportInterval: '1s' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make it 10s
|
||
function setupTraceExporter(): SpanExporter | undefined { | ||
console.log('[Instrumentation] Setting up Trace Exporter to', OTEL_EXPORTER_OTLP_ENDPOINT); | ||
return new OTLPTraceExporterGrpc({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing auth headers
headers: {
'signoz-ingestion-key': xxx,
},
function setupMetricReader() { | ||
console.log('[Instrumentation] Setting up Metric Reader to', OTEL_EXPORTER_OTLP_ENDPOINT); | ||
return new PeriodicExportingMetricReader({ | ||
exporter: new OTLPMetricExporterGrpc({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing auth headers
headers: {
'signoz-ingestion-key': xxx,
},
} | ||
|
||
export const resource = new Resource({ | ||
[ATTR_SERVICE_NAME]: OTEL_RESOURCE_ATTRIBUTES.split(',')[0].split('=')[1], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this only parses the 0th element of the array.
SERVICE_NAME
might not necessarily be at 0th position- We must parse all attributes
Fixes: #1156