question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Problem with more then one span

See original GitHub issue

I observe very strange behavior. If the application has more than one span, then information about them is not sent to the collector (I use Jaeger).

This works and I can see span in Jaeger:

  @Span('doSomething')
  async doSomething() {
    console.log('');
  }

But this code does not send any spans to Jaeger:

  @Span('doSomething')
  async doSomething() {
    console.log('doSomething');
  }

  @Span('doSomethingElse')
  async doSomethingElse() {
    console.log('doSomethingElse');
  }

I also get the same behavior if I add any nested span using TraceService or if I add any instrumentation.

I use next config:

const OpenTelemetryModuleConfig = OpenTelemetryModule.forRoot({
  metrics: {
    hostMetrics: true,
    defaultMetrics: true, 
    apiMetrics: {
      enable: true, 
      timeBuckets: [],
    },
  },
  nodeSDKConfiguration: {
    spanProcessor: new BatchSpanProcessor(new JaegerExporter({
      host: 'host.docker.internal',
      port: 6832,
    })),
    contextManager: new AsyncLocalStorageContextManager(),
    textMapPropagator: new CompositePropagator({
      propagators: [
        new B3Propagator(),
        new B3Propagator({
          injectEncoding: B3InjectEncoding.MULTI_HEADER,
        }),
      ],
    }),
    resource: new Resource({
      [ResourceAttributes.SERVICE_NAME]: 'stl',
    }),
  },
});

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
pragmaticivancommented, Jul 14, 2021

@chrismllr I’ve just added a full example: https://github.com/pragmaticivan/nestjs-otel/tree/main/examples/nestjs-prom-grafana-tempo

This one has grafana + prometheus + tempo + jaeger ui. In the logs you can copy the traceId and can search it on Jaeger UI or Tempo directly on Grafana.

0reactions
chrismllrcommented, Jul 13, 2021

@kosmos Would you mind sharing your docker-compose (or otherwise) configuration to get the messages from your nest server over to jaeger? I am having trouble with that connection, and have tried the endpoint config as well as the host/port configs.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Can I use more then one span in a link? - Stack Overflow
Yes you can have as many span as you will need.
Read more >
Troubleshooting | OneSpan Community Platform
Provides troubleshooting help on possible issues with OneSpan Sign for Microsoft SharePoint.
Read more >
OneSpan Modernizes High Assurance ... - Business Wire
OneSpan's new cloud-connected DIGIPASS CX devices bring the highest level of assurance to the ever-growing problem of identity and credential ...
Read more >
OneSpan Sign Pricing, Alternatives & More 2022 - Capterra
Moving completely to an online system worked well for us. A few students had issues when they started an application, and then didn't...
Read more >
Continuous vs. Single-Span Joists - JLC Online
These days you really only see this problem with engineered joists because it is difficult to find conventional lumber in lengths greater than...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found