This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-10-31
Channels
- # aleph (8)
- # announcements (11)
- # aws (1)
- # babashka (7)
- # beginners (104)
- # calva (52)
- # clara (1)
- # clj-kondo (28)
- # cljdoc (8)
- # cljsrn (2)
- # clojure (20)
- # clojure-europe (8)
- # clojure-uk (1)
- # clojurescript (26)
- # core-typed (3)
- # datomic (6)
- # holy-lambda (1)
- # jobs (1)
- # jobs-discuss (14)
- # malli (7)
- # pathom (31)
- # polylith (19)
- # re-frame (8)
- # reitit (1)
- # releases (1)
- # shadow-cljs (5)
- # tools-build (92)
Hi, everyone! I am trying to add datadog JVM agent to Datomic transactor (on prem) java process but it doesn't seem the -javaagent
JVM setting is being picked up. I noticed this https://ask.datomic.com/index.php/458/can-you-start-the-datomic-jvm-with-a-custom-jvm-agent while investigating. Is adding a JVM agent doable with Datomic on prem? We are at 0.9.6045.
Take a look at the startup script at bin/transactor. Either you can find an env var it reads and use it to set Java opts, or you can replicate what it does yourself and add more args (it’s not very complex).
Thanks @U09R86PA4, yes, I added a javaagent
. Here is the process
00:02:33 java -server -cp resources:datomic-transactor-pro-0.9.6045.jar:lib/*:samples/clj:bin: -Xmx4g -Xms4g -XX:+UseG1G
C -XX:MaxGCPauseMillis=50 -XX:+ExitOnOutOfMemoryError -XX:HeapDumpPath=/opt/datomic-pro-0.9.6045 -Ddatomic.peerConnectionTTLMsec=60000 -javaagent:./dd-java-age
nt.jar clojure.main --main datomic.launcher /opt/datomic-pro-0.9.6045/config/transactor.properties
But I don't see any startup log which should appear if it is working fine https://docs.datadoghq.com/tracing/troubleshooting/tracer_startup_logs
I have ruled out a few possibilities
• the log is muted
• the dd-java-agent.jar is corrupted
• datadog-agent APM agent is not running fine
After seeing the mentioned post, I am wondering if it is just custom JVM agent is disabled for transactor (on prem or cloud)I believe a javaagent param may need to go before jar or cp params to work? I notice dd also has some other configuration you can add to make it noisier to make sure it’s loading and working https://docs.datadoghq.com/tracing/setup_overview/setup/java/?tab=containers
I’m not aware of any way a Java program can disable or circumvent a static agent. I’m not sure how that link gave you that impression
you are absolutely correct that javaagent
param needs to go before jar or cp params. @U09R86PA4! Thanks a lot~