elastic / elastic/apm-agent-java

Add Span#deactivate to the public API

Aperta
#780 4 commenti 0 reazioni 0 assegnatari Vedi su GitHub
api
Lingua principale
Java
Stelle
594
Fork
338
Merge medio
1g 13h
PR unite (30g)
25

Descrizione

Currently, the public API does not allow for `deactivation` of active Transactions and Spans arbitrarily. The only way to deactivate is by keeping the `Scope` reference returned from the `activate` API.

An example where this would be required - [this discuss topic](https://discuss.elastic.co/t/spring-kafka-instrumentation-kafkalistenerendpointcontainer-mono-thread/193810).

I also found this limiting when implemented [this context propagation example](https://github.com/elastic/apm-agent-java/blob/24f60f9fcef59c58ad99d848efc28f14d6c772d1/apm-agent-plugins/apm-api-plugin/src/test/java/co/elastic/apm/api/BlockingQueueContextPropagationTest.java)

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.