Skip to content

OTLP Metrics and Tracing Not Initialising #7281

Closed

Description

@rlaveycal

I can't get the OTLP metrics and tracing plugins to initialise. I'm deploying via the Helm chart.

Version: 26.9.1

Helm Config:

  arcadedb:
    plugins:
      prometheus:
        enabled: true
        requireAuthentication: false
  observability:
    metrics:
      otlp:
        enabled: true
        endpoint: http://otel-agent.sf-infra:4317
    tracing:
      enabled: true
      endpoint: http://otel-agent.sf-infra:4317
      samplingRate: 1.0

Command Args

The chart generates this:

-Darcadedb.server.plugins=Prometheus:com.arcadedb.metrics.prometheus.PrometheusMetricsPlugin 
-Darcadedb.serverMetrics.prometheus.requireAuthentication=false                                                                                                                              
-Darcadedb.serverMetrics.otlp.enabled=true                                                                                                                                                   
-Darcadedb.serverMetrics.otlp.endpoint=http://otel-agent.sf-infra:4317                                                                                                      
-Darcadedb.serverMetrics.tracing.enabled=true                                                                                                                                                
-Darcadedb.serverMetrics.tracing.endpoint=http://otel-agent.sf-infra:4317                                                                                                   
-Darcadedb.serverMetrics.tracing.samplingRate=1                                                                                                                                              

Startup log

The startup logs what appears to be the default values rather than the actual runtime values

ARCADEDB 26.9.1 configuration:
- ARCADEDB
  + arcadedb.dumpConfigAtStartup = true
  + arcadedb.dumpMetricsEvery = 0
  + arcadedb.server.logIncludeTrace = false
  + arcadedb.serverMetrics = true
  + arcadedb.serverMetrics.logging = false
  + arcadedb.serverMetrics.tracing.enabled = false
  + arcadedb.serverMetrics.tracing.endpoint = http://localhost:4317
  + arcadedb.serverMetrics.tracing.samplingRate = 0.0
  + arcadedb.server.mode = development

/api/v1/server

Filtered for $_.key -like "*metric*". There are no otlp settings

key         : arcadedb.dumpMetricsEvery
value       : 0
description : Dumps the metrics at startup, shutdown and every configurable amount of time (in seconds)
overridden  : False
default     : 0

key         : arcadedb.serverMetrics
value       : True
description : True to enable metrics
overridden  : False
default     : True

key         : arcadedb.serverMetrics.logging
value       : False
description : True to enable metrics logging
overridden  : False
default     : False

key         : arcadedb.serverMetrics.tracing.enabled
value       : True
description : Enable OpenTelemetry distributed tracing (requires the optional tracing plugin on the classpath). Note: query/command spans include the statement text as the db.statement span
              attribute, which may contain sensitive data, so secure the OTLP collector endpoint
overridden  : False
default     : False

key         : arcadedb.serverMetrics.tracing.endpoint
value       : http://otel-agent.sf-infra:4317
description : OTLP trace export endpoint
overridden  : False
default     : http://localhost:4317

key         : arcadedb.serverMetrics.tracing.samplingRate
value       : 1
description : Parent-based trace sampling ratio in [0.0,1.0]
overridden  : False
default     : 0

Observations:

  1. Prometheus plugin is operational (can query and scrape)
  2. No log messages showing startup of either tracing or OTLP plugins

What am I missing?

Activity

  1. added
    observability
    on Sep 8, 2026
  2. added this to the 26.10.1 milestone on Sep 8, 2026
  3. self-assigned this
    on Sep 8, 2026
  4. robfrank commented on Sep 8, 2026

    @robfrank
    Collaborator

    What's happening: both OtlpMetricsPlugin and TracingPlugin are ServerPlugins discovered via ServiceLoader, and PluginManager only activates a discovered plugin if it is either named in arcadedb.server.plugins or returns true from ServerPlugin.isAutoDiscovered(). That method defaults to false and neither plugin overrides it, so the arcadedb.serverMetrics.otlp.enabled / arcadedb.serverMetrics.tracing.enabled flags you set have no effect on activation: configure() is never called, which is exactly why you see no log lines. Prometheus works only because the chart adds it to arcadedb.server.plugins explicitly.

    The jars themselves are fine - arcadedb-metrics-26.9.1-shaded.jar and arcadedb-tracing-26.9.1-shaded.jar both ship in the 26.9.1 image with the right META-INF/services entries. It is purely the activation gate.

    Workaround for 26.9.1 - register the two plugins explicitly. The chart requires a port for any plugin it doesn't know built-in, so pass unused dummy ports (they will show up in the Service, which is harmless):

    arcadedb:
      plugins:
        prometheus:
          enabled: true
          requireAuthentication: false
        otlp:
          enabled: true
          port: 14317        # unused, the chart requires a port for custom plugins
          class: com.arcadedb.metrics.otlp.OtlpMetricsPlugin
        tracing:
          enabled: true
          port: 14318        # unused
          class: com.arcadedb.tracing.TracingPlugin
    observability:
      metrics:
        otlp:
          enabled: true
          endpoint: http://otel-agent.sf-infra:4317
      tracing:
        enabled: true
        endpoint: http://otel-agent.sf-infra:4317
        samplingRate: 1.0

    Keep the observability: block as you have it - it supplies the endpoint and sampling flags; the plugins: entries only turn the plugins on. After that you should see Discovered plugin on main class loader: ..., OTLP metrics export enabled, and the tracing startup line.

    Note that JAVA_OPTS via extraEnvironment is not a workaround here: the chart's own -Darcadedb.server.plugins=... appears later on the command line and wins.

    Two more things your report uncovered, which we'll fix as well:

    1. The startup configuration dump is printed from the arcadedb.dumpConfigAtStartup callback, which is the first entry in the settings enum, so settings declared after it have not had their -D values applied yet when it runs. That's why the dump showed tracing.enabled = false while /api/v1/server correctly reports true. Misleading output, no functional impact.
    2. arcadedb.serverMetrics.otlp.enabled and .endpoint are not registered settings at all - the plugin reads them through a raw system-property fallback - which is why they are absent from /api/v1/server. They will be registered properly alongside the tracing ones.
  5. added
    in progress
    server
    engine
    on Sep 8, 2026
  6. added 3 commits that reference this issue on Sep 8, 2026
  7. robfrank commented on Sep 8, 2026

    @robfrank
    Collaborator

    This is fixed in #7283, which just merged.

    The root cause: ArcadeDB only starts a plugin whose classpath jar is present when either it's named in arcadedb.server.plugins or the plugin declares itself auto-discovered. Neither the OTLP metrics plugin nor the tracing plugin declared themselves that way, so setting arcadedb.serverMetrics.otlp.enabled / arcadedb.serverMetrics.tracing.enabled had no effect on whether the plugin ever started - the setting was stored and reported back correctly (which is why /api/v1/server showed the right values), but the plugin code that reads it never ran. Both plugins now start automatically once their own enable flag is set, with no arcadedb.server.plugins entry required - which matches how the Helm chart's observability: block already configures them.

    Two related issues you surfaced are fixed in the same PR:

    • The startup configuration dump was printing default values for settings declared after the "dump config" setting itself, rather than the values actually applied - that's why the log looked stale compared to /api/v1/server.
    • arcadedb.serverMetrics.otlp.enabled and .endpoint weren't registered settings, so they never showed up in /api/v1/server at all even though they worked as a raw system property.

    Still open: nothing from your report is deferred. A follow-up gap found while investigating - a plugin dropped into lib/plugins/ had the same activation problem via a second code path - is fixed in the same PR too, so there's no separate issue to track there. A chart-side stopgap was also filed for older releases: ArcadeData/arcadedb-helm#24.

    This will ship in the next release after 26.9.1. Thanks for the very thorough report - the exact -D flags and the /api/v1/server diff made the root cause easy to pin down.


    ❤️ Thanks for helping make ArcadeDB better! ArcadeDB is free and open source, sustained by its community. If it's useful to you or your company, please consider becoming a sponsor to keep development going.

  8. removed
    in progress
    on Sep 8, 2026
  9. robfrank commented on Sep 15, 2026

    @robfrank
    Collaborator

    helm chart updated : ArcadeData/arcadedb-helm#25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugengineobservabilityserver

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions