Fix idea compile for mongo modules
MODIFY
dd-java-agent/integrations/mongo-3.1/src/main/java/dd/inst/mongo/MongoClientInstrumentation.java
dd-java-agent/integrations/mongo-3.1/src/main/java/dd/inst/mongo/MongoClientInstrumentation.java
@@ -24,14 +24,14 @@ public final class MongoClientInstrumentation implements Instrumenter {
.and(
declaresMethod(
named("addCommandListener")
- .and(isPublic())
.and(
takesArguments(
new TypeDescription.Latent(
"com.mongodb.event.CommandListener",
Modifier.PUBLIC,
null,
- new TypeDescription.Generic[] {}))))))
+ new TypeDescription.Generic[] {})))
+ .and(isPublic()))))
.transform(
DDAdvice.create()
.advice(

MODIFY
dd-java-agent/integrations/mongo-async-3.3/src/main/java/dd/inst/mongo/MongoAsyncClientInstrumentation.java
dd-java-agent/integrations/mongo-async-3.3/src/main/java/dd/inst/mongo/MongoAsyncClientInstrumentation.java
@@ -24,14 +24,14 @@ public final class MongoAsyncClientInstrumentation implements Instrumenter {
.and(
declaresMethod(
named("addCommandListener")
- .and(isPublic())
.and(
takesArguments(
new TypeDescription.Latent(
"com.mongodb.event.CommandListener",
Modifier.PUBLIC,
null,
- new TypeDescription.Generic[] {}))))))
+ new TypeDescription.Generic[] {})))
+ .and(isPublic()))))
.transform(
DDAdvice.create()
.advice(

Fix idea compile for mongo modules