Wir haben einen Akka HTTP Server, der einige Scala JS Inhalte auf AWS bereitstellt. Wir haben festgestellt, dass der Server nach einiger Zeit beginnt, den Fehler unten in den Protokollen auszugeben und obwohl die bestimmte URL funktioniert, aber einige Dateien nicht korrekt mit dem Failed to load resource: net::ERR_CONTENT_LENGTH_MISMATCH
Fehler im Browser heruntergeladen werden können. Der Server-Logs sieht aus wie unten (es ist genau der gleiche Fehler in allen Fällen):Akka Http Fehler: InvalidContentLengthException
[ERROR] [09/29/2016 21:29:22.150] [designer-actor-system-akka.actor.default-dispatcher-56831] [akka.actor.ActorSystemImpl(designer-actor-system)] Outgoing response stream error akka.http.scaladsl.model.InvalidContentLengthException: HTTP message had declared Content-Length 997 but entity data stream amounts to 164 bytes less at akka.http.scaladsl.model.InvalidContentLengthException$.apply(ErrorInfo.scala:50) at akka.http.impl.engine.rendering.RenderSupport$CheckContentLengthTransformer$$anon$2.onUpstreamFinish(RenderSupport.scala:130) at akka.stream.impl.fusing.GraphInterpreter.processEvent(GraphInterpreter.scala:732) at akka.stream.impl.fusing.GraphInterpreter.execute(GraphInterpreter.scala:616) at akka.stream.impl.fusing.GraphInterpreterShell.runBatch(ActorGraphInterpreter.scala:471) at akka.stream.impl.fusing.GraphInterpreterShell.receive(ActorGraphInterpreter.scala:433) at akka.stream.impl.fusing.ActorGraphInterpreter.akka$stream$impl$fusing$ActorGraphInterpreter$$processEvent(ActorGraphInterpreter.scala:603) at akka.stream.impl.fusing.ActorGraphInterpreter$$anonfun$receive$1.applyOrElse(ActorGraphInterpreter.scala:618) at akka.actor.Actor$class.aroundReceive(Actor.scala:484) at akka.stream.impl.fusing.ActorGraphInterpreter.aroundReceive(ActorGraphInterpreter.scala:529) at akka.actor.ActorCell.receiveMessage(ActorCell.scala:526) at akka.actor.ActorCell.invoke(ActorCell.scala:495) 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)
Wir laufen Akka Version 2.4.7 und OpenJDK-Version 1.8.0_101-b13.The Fehler gehen weg, wenn wir die Akka neu starten HTTP-Server, kommt aber nach ein paar Stunden wieder zurück.
Nicht sicher, was das Problem verursacht. Jede Hilfe würde sehr geschätzt werden.