Pull requests for bug fixes are always welcome!
Before submitting new features or changes to current functionality, it is recommended to first open an issue and discuss your ideas or propose the changes you wish to make.
In order to build and test this whole repository you need JDK 11+.
Build using Java 11+:
java -version
./gradlew assemble
and then you can find the java agent artifact at
agent/agent/build/libs/applicationinsights-agent-<version>.jar
.
See IntelliJ setup and troubleshooting from the OpenTelemetry Java Instrumentation project.
See the style guide. from the OpenTelemetry Java Instrumentation project.
Pick the smoke test that you want to run, e.g. MongoTest
.
If the smoke test is abstract, then pick one of its subclasses, e.g. MongoTest$Tomcat8Java8Test
.
Right-click on it and select run.
Add -PsmokeTestRemoteDebug=true
to the gradle args, e.g.
Then create a Remote JVM Debug configuration, e.g.
Then run (not debug) the smoke test as above in Running the smoke tests from Intellij.
The JVM inside the container will wait remote debugger to be attached before starting.
Then go to Run > Debug, and select your Remote JVM Debug configuration.
While developing, if you find errorprone is getting in your way (e.g. it won't let you add
System.out.println
to your code), you can disable it by adding the following to your
~/.gradle/gradle.properties
:
disableErrorProne=true