We are using elastic apm in a micro-service environment and we have some 404 response from internal APIs that are totally acceptable, like verifying if a resource exists, but those are reported as erros in the Dependency tab.
Is there a way, in code, to ignore specific 404 span errors from http dependencies?
Looking at the code from Github, the span is ending in postHook just after the curl execution and I don't see how one can intercept it.
I realized just a few minutes too late that this strategy might not work here as the dependencies rely on metrics that are derived from the HTTP spans, so modifying the span data before it is written in ES does not help to keep those metrics consistent.
Sorry for the noise !
As a consequence, you might have to use an agent-specific way to do the same.
Which APM agent are you using here ? Not all of them provide such functionality, but from memory I think the node.js one does.