-
Notifications
You must be signed in to change notification settings - Fork 314
Closed
Labels
comp: asm wafApplication Security Management (WAF)Application Security Management (WAF)type: bugBug report and fixBug report and fix
Description
Tracer Version(s)
1.51.0
Java Version(s)
21.0.7
JVM Vendor
Amazon Corretto
Bug Report
Hello!
We updated some of our Java services today with the latest (1.51.0) tracer agent and are suffering from NPE:s thrown here due to this.mergedAsmFeatures
not being set.
The error output is:
java.lang.NullPointerException: Cannot invoke "com.datadog.appsec.config.MergedAsmFeatures.getMergedData()" because "this.mergedAsmFeatures" is null
at com.datadog.appsec.config.AppSecConfigServiceImpl.applyRemoteConfigListener(AppSecConfigServiceImpl.java:508)
at datadog.remoteconfig.DefaultConfigurationPoller.runConfigurationEndListener(DefaultConfigurationPoller.java:448)
at datadog.remoteconfig.DefaultConfigurationPoller.handleAgentResponse(DefaultConfigurationPoller.java:436)
at datadog.remoteconfig.DefaultConfigurationPoller.sendRequest(DefaultConfigurationPoller.java:343)
at datadog.remoteconfig.DefaultConfigurationPoller.poll(DefaultConfigurationPoller.java:243)
at datadog.trace.util.AgentTaskScheduler$PeriodicTask.run(AgentTaskScheduler.java:311)
at datadog.trace.util.AgentTaskScheduler$Worker.run(AgentTaskScheduler.java:266)
at java.base/java.lang.Thread.run(Thread.java:1583)
We are running the agent without any custom AppSec configuration. It seems this.mergedAsmFeatures
is only initialized via init()
, but applyRemoteConfigListener()
can run before init()
is triggered, leading to the NPE.
Expected Behavior
Ensure mergedAsmFeatures
is initialized before calling applyRemoteConfigListener
Reproduction Code
No response
tomjo, RedVortex, andcea, lmhajdukd and markgholland
Metadata
Metadata
Assignees
Labels
comp: asm wafApplication Security Management (WAF)Application Security Management (WAF)type: bugBug report and fixBug report and fix