=AFQjCNFk7u2ednXynJOI5ubpUSi7sKawQA).
That flattens out the Futures and you get responses instead. That also
makes Balance actually aware of response times.
OTOH I don't think performance wise akka-http is currently up to the task
of being a balancer.
-Endre
On Wed, May 27, 2015 at 1:21 PM, zergood zergoo
Hello!
I have a task to develop a http balance loader for my 2 servers. Here is my
qucik and very dirty implementation
https://gist.github.com/zergood/e705cd6ce4cfec47c0a5. The main problem with
it is performance, this solution is slower than my single server.
What is the reason
I've done little benchmarks to compare spray and akka-http performance. I
use default jvm and akka settings. So you can see that there is
an significant performance difference between it.
code:
spray https://gist.github.com/zergood/18bae0adc2e774c31233.
akka-http https://gist.github.com
performance in later versions though.
We basically refactored streams API in roughly every second release, so we
are currently happy that the current API looks usable and most of the bugs
are ironed out.
-Endre
On Wed, May 27, 2015 at 1:44 PM, zergood zergoo...@gmail.com
javascript
:23 PM, zergood zergoo...@gmail.com javascript:
wrote:
Hello!
My server side:
def update: Iterator[ByteString]
lazy val binding = StreamTcp(system).bind(address, idleTimeout =
20.seconds)
def start(): Future[Unit] = {
val firstCompleted = Promise[Unit]()
val
:47 PM, zergood zergoo...@gmail.com javascript:
wrote:
Thank you for your answer.
But If I use onCompleteSink after connection flow, future will not be
completed successfully however data will be downloaded by client.
The only reason for that could be that the client does not close
Is there an api for closing client connection?
вторник, 7 апреля 2015 г., 16:40:46 UTC+3 пользователь Akka Team написал:
On Tue, Apr 7, 2015 at 3:38 PM, zergood zergoo...@gmail.com javascript:
wrote:
Here is my client code:
def downloadUpdate(address: InetSocketAddress
Hello!
My server side:
def update: Iterator[ByteString]
lazy val binding = StreamTcp(system).bind(address, idleTimeout =
20.seconds)
def start(): Future[Unit] = {
val firstCompleted = Promise[Unit]()
val foreachConnection = ForeachSink[IncomingConnection] {
connection =
I had found the issue. The reason was frame coding. I supposed that every
message is send in single tcp packet but it is not. Now I have implemented
frame coding/decoding and everything is fine. Thank you for answers!
четверг, 19 марта 2015 г., 15:54:46 UTC+3 пользователь zergood написал:
Hi
Hi!
I want to stream file lines through tcp to server.
Here is the code:
class StreamingTcpActor(remoteAddress:InetSocketAddress, system: ActorSystem){
implicit val actorSystem = system
implicit val materializer = ActorFlowMaterializer()
val connection =
10 matches
Mail list logo