Search…
JVM
Execute the following commands in all the namespaces which you want to install the Traceable Java Module. This will automatically instrument any applications in the namespace running in the JVM. See our framework compatibility matrix to ensure this option is right for you
1
kubectl label namespace $NAMESPACE traceableai-inject-java=enabled
Copied!
1
kubectl annotate namespace $NAMESPACE java.traceable.ai/defaultInject='true'
Copied!
Once the label and annotations are applied, restart the deployments for the pods you wish to protect.

Verify

If all goes well, when you print the logs for the traceable-agent-xxxx pod, you should see a message similar to the following
1
kubectl logs traceable-agent-xxxx-xxxx -n traceableai
Copied!
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 11.0px Menlo; color: #000000; background-color: #ffffff} span.s1 {font-variant-ligatures: no-common-ligatures}
{"level":"info","time":"2021-09-29T04:38:06.402Z","message":"Annotation found in ObjectMeta","injector":"java","object_type":"Namespace","object_name":"example","annotation_key":"java.traceable.ai/defaultInject","annotation_value":"true"}
{"level":"info","time":"2021-09-29T04:38:06.402Z","message":"Will execute injection on pod","injector":"java","pod_name":"example-v1-bcc958cfd-","namespace_name":"example"}
Last modified 2mo ago
Export as PDF
Copy link
Contents
Verify