Node fails when trying to connect with Akka remote

45 views
Skip to first unread message

Danny Lesnik

unread,
Oct 23, 2016, 7:45:25 AM10/23/16
to kamon-user
I've frontend and backend server. 

Frontend runs Play! 2.5 and akka 2.4.11
Backend runs akka 2.4.11

Both running kamon 0.6.3, 
and has the following dependencies: 

"io.kamon" %% "kamon-akka" % Version.kamon,
"io.kamon" %% "kamon-log-reporter" % Version.kamon,
"io.kamon" %% "kamon-system-metrics" % Version.kamon,
"io.kamon" %% "kamon-core" % Version.kamon,
"io.kamon" %% "kamon-akka-remote" % Version.kamon,
"io.kamon" %% "kamon-statsd" % Version.kamon,
"io.kamon" % "kamon-play-25_2.11" % Version.kamon

In build.sbt I have the following:

aspectjSettings
javaOptions <++= AspectjKeys.weaverOptions in Aspectj
fork in run := true

I'm starting backend with the aspectj weaver:
-javaagent:./aspectjweaver/aspectjweaver-1.8.9.jar

In plugins.sbt I added the folllowing plugin:

addSbtPlugin("io.kamon" % "aspectj-play-runner" % "0.1.3")

However when I start backend and frontend, I'm getting the following exception immidiately as my frontend node joins 
backend cluster.

java.lang.NoSuchFieldError: PARSER
	at akka.remote.instrumentation.TraceContextAwareWireFormats$TraceContextAwareRemoteEnvelope.<init>(TraceContextAwareWireFormats.java:859)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$TraceContextAwareRemoteEnvelope.<init>(TraceContextAwareWireFormats.java:806)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$TraceContextAwareRemoteEnvelope$1.parsePartialFrom(TraceContextAwareWireFormats.java:941)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$TraceContextAwareRemoteEnvelope$1.parsePartialFrom(TraceContextAwareWireFormats.java:936)
	at com.google.protobuf.CodedInputStream.readMessage(CodedInputStream.java:309)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$AckAndTraceContextAwareEnvelopeContainer.<init>(TraceContextAwareWireFormats.java:111)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$AckAndTraceContextAwareEnvelopeContainer.<init>(TraceContextAwareWireFormats.java:45)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$AckAndTraceContextAwareEnvelopeContainer$1.parsePartialFrom(TraceContextAwareWireFormats.java:149)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$AckAndTraceContextAwareEnvelopeContainer$1.parsePartialFrom(TraceContextAwareWireFormats.java:144)
	at com.google.protobuf.AbstractParser.parsePartialFrom(AbstractParser.java:141)
	at com.google.protobuf.AbstractParser.parseFrom(AbstractParser.java:176)
	at com.google.protobuf.AbstractParser.parseFrom(AbstractParser.java:188)
	at com.google.protobuf.AbstractParser.parseFrom(AbstractParser.java:193)
	at com.google.protobuf.AbstractParser.parseFrom(AbstractParser.java:49)
	at akka.remote.instrumentation.TraceContextAwareWireFormats$AckAndTraceContextAwareEnvelopeContainer.parseFrom(TraceContextAwareWireFormats.java:279)
	at akka.kamon.instrumentation.RemotingInstrumentation.aroundDecodeRemoteMessage(RemotingInstrumentation.scala:82)
	at akka.remote.transport.AkkaPduProtobufCodec$.decodeMessage(AkkaPduCodec.scala:187)
	at akka.remote.EndpointReader.akka$remote$EndpointReader$$tryDecodeMessageAndAck(Endpoint.scala:1043)
	at akka.remote.EndpointReader$$anonfun$receive$2.applyOrElse(Endpoint.scala:974)
	at akka.actor.Actor$class.aroundReceive(Actor.scala:484)
	at akka.remote.EndpointActor.aroundReceive(Endpoint.scala:449)
	at akka.actor.ActorCell.receiveMessage(ActorCell.scala:526)
	at akka.actor.ActorCell.invoke_aroundBody0(ActorCell.scala:495)
	at akka.actor.ActorCell$AjcClosure1.run(ActorCell.scala:1)
	at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149)
	at akka.kamon.instrumentation.ActorMonitors$$anon$1$$anonfun$processMessage$1.apply(ActorMonitor.scala:59)
	at kamon.trace.Tracer$.withContext(TracerModule.scala:58)
	at akka.kamon.instrumentation.ActorMonitors$$anon$1.processMessage(ActorMonitor.scala:58)
	at akka.kamon.instrumentation.ActorCellInstrumentation.aroundBehaviourInvoke(ActorInstrumentation.scala:44)
	at akka.actor.ActorCell.invoke(ActorCell.scala:488)
	at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:257)
	at akka.dispatch.Mailbox.run(Mailbox.scala:224)
	at akka.dispatch.Mailbox.exec(Mailbox.scala:234)
	at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
	at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
	at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
	at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)

Can you please help?

Ivan Topolnjak

unread,
Oct 23, 2016, 7:52:50 AM10/23/16
to kamon-user
Hello Danny,

Could you please try using "kamon-akka-remote_akka-2.4"? It you are using Akka 2.4 you should change to this one. Please let us know if the problem persists after the change, regards!

--
You received this message because you are subscribed to the Google Groups "kamon-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kamon-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Danny Lesnik

unread,
Oct 24, 2016, 1:35:56 PM10/24/16
to kamon-user
Hello Ivan, 

Yes it solved the problem.
Thank you very much.

Danny.
Reply all
Reply to author
Forward
0 new messages