Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-14324

Brave MDC Integration fails in Karaf due to missing class CorrelationFieldScopeDecorator

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Won't Fix
    • None
    • 3.x
    • camel-zipkin
    • None
    • Unknown

    Description

      When useMDCLogging is set to true on a CamelContext with camel-zipkin, the application fails to start. The error message is java.lang.NoClassDefFoundError: brave/internal/propagation/CorrelationFieldScopeDecorator.

      The reason might be that the brave.context.slf4j.MDCScopeDecorator from brave-context-slf4j, introduced into ZipkinTracer with CAMEL-12721, extends brave.internal.propagation.CorrelationFieldScopeDecorator, which seems not to get exported by the brave bundle https://github.com/openzipkin/brave/tree/5.6.5/brave, according to its bnd file (https://github.com/openzipkin/brave/blob/5.6.5/brave/bnd.bnd). Possibly this is why the instance creation fails.

      The solution could be to use only exported brave classes (effectively recreating MDCScopeDecorator) or maybe let OSGi create the MDCScopeDecorator instance.

      Attachments

        Activity

          People

            Unassigned Unassigned
            dschulten Dietrich Schulten
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: