I'm running a trial on Elastic Cloud and I'm trying to instrument a Node.js API.
In general, the transactions are showing just fine.
However, I think there's two items that are not working well.
Mongoose not being instrumented
I see other modules (ie session) which are using the same mongo connection that get database spans.
Some calls do get instrumented, like new Model({}).save(). On the other hand, stuff like find or findOneAndUpdate are not getting instrumented.
No "own" code spans
Please correct me if I am wrong but the agent is supposed to trace our own code.
We can see find calls just fine using mongoose and elastic-apm-node v2.16.2. We're using the ES6 import fix with elastic-apm-node/start to make sure we import the lib at the very top. Maybe that is your issue?
Unfortunately no luck.
We're using Typescript, and the import just like mentioned in the documentation.
It's not the very very first import item tho. dotenv comes first but that shouldn't be causing this.
I'm having a hard time understanding why it works for certain write operations but never for read ops.
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.