akka-tracing icon indicating copy to clipboard operation
akka-tracing copied to clipboard

activator-play-tracing with Play 2.5

Open austek opened this issue 10 years ago • 4 comments

Is it possible to either list what changes to make to activator-play-tracing or update the project to make it work with Play 2.5 as they have made some breaking changes and I couldn't get tracing to work?

austek avatar Apr 01 '16 09:04 austek

I have started migration to work with play 2.5, but currently all doesn't work. Connection to zipkin server is successful but trace are not submitted

https://github.com/levkhomich/akka-tracing/pull/71 https://github.com/levkhomich/activator-play-tracing/pull/1

austek avatar Apr 10 '16 19:04 austek

its because of this in GlobalSettings, which TracingSettings overrides.

i'll see if i can fix it.

@deprecated("onRequestCompletion is no longer invoked by Play. The same functionality can be achieved by adding a filter that attaches a onDoneEnumerating callback onto the returned Result Enumerator.", "2.4.0") def onRequestCompletion(request: RequestHeader) { }

monkeygroover avatar Apr 13 '16 21:04 monkeygroover

https://github.com/monkeygroover/akka-tracing/commit/f35e7467b2fb32031f2abe6b84bfbead15fe9143

quick test to see if a filter will work. (note I only tried 2.4 not 2.5 yet)

add, this in the root of the project.

class Filters extends HttpFilters {

import play.api.libs.concurrent.Execution.Implicits._ val traceEndHookFilter = new TracingFilter()

val filters = Seq(traceEndHookFilter) }

monkeygroover avatar Apr 14 '16 08:04 monkeygroover

I've tried this approach myself but when it tries to submit the span I receive the following frame size error:

WARN [application-akka.actor.default-dispatcher-2] [Slf4jLogger.scala:76] - Thrift transport error: Frame size (1213486160) larger than max length (16384000)!. Failed to send 1 spans. - [sourceThread=application-akka.actor.default-dispatcher-5, akkaSource=akka://application/user/spanHolder/spanSubmitter, sourceActorSystem=application, akkaTimestamp=12:45:52.831UTC] - [] -

class Filters @Inject()(tracingFilter: TracingFilter) extends HttpFilters { val filters = Seq(tracingFilter) }

tsteff avatar Jan 18 '17 12:01 tsteff