I've written a couple of simple plugins to cover some unsupported cases in legacy code.
I'm considering another such case where all I really need is to extend co.elastic.apm.agent.concurrent.ExecutorRunnableInstrumentation and change the getTypeMatcher method.
Is this a reasonable dependency or should I consider ExecutorRunnableInstrumentation to be an implementation detail that I should not rely on?
Can you elaborate a bit on the unsupported cases in legacy code here ?
Generally speaking it's tricky to have cross-instrumentation dependencies, and maybe there are alternative ways than directly depending on instrumentation implementation details.
For the new case I have in mind, a team took the old util.concurrent library, renamed the packages, and added it to their own codebase. Supporting transferring the trace context across threads would be exactly like the agent does for java.util.concurrent except the package names are different.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.