Re: [akka-user] Re: Slowing down Akka HTTP responses

2017-03-29 Thread Alan Burlison
On 29/03/2017 16:38, Rafał Krzewski wrote: How about something like: complete { Source.single(yourResponse).via(Flow.delay(delayDuration)).to(Sink.head).run() } I'm shooting from the hip here, you may need to use the type of your response as parameter somewhere in the middle. The idea is that

[akka-user] Re: Slowing down Akka HTTP responses

2017-03-29 Thread Rafał Krzewski
How about something like: complete { Source.single(yourResponse).via(Flow.delay(delayDuration)).to(Sink.head).run() } I'm shooting from the hip here, you may need to use the type of your response as parameter somewhere in the middle. The idea is that Sink.head[T] materializes into a

Re: [akka-user] Akka HTTP/JSON: Rejecting requests with unknown fields

2017-03-29 Thread Alan Burlison
On 29/03/2017 12:13, Konrad Malawski wrote: In principle sure, though not on anyones roadmap nowadays. You could contribute such a thing or find a json parser whihc has such failure mode - I'm unaware of any parser which has such failure mode though. I can't think of any way of doing it that

Re: [akka-user] Akka HTTP/JSON: Rejecting requests with unknown fields

2017-03-29 Thread Konrad Malawski
In principle sure, though not on anyones roadmap nowadays. You could contribute such a thing or find a json parser whihc has such failure mode - I'm unaware of any parser which has such failure mode though. -- Konrad `ktoso` Malawski Akka @ Lightbend On