Re: [akka-user] performance drops when upgrade from akka 2.2.3 to 2.3.4 with default config

2014-08-07 Thread Endre Varga
Sean, Yes the separate dispatcher might be the cause. This default was added to protect the remoting subsystem from load in userspace (learning from some past problems). Feel free to reconfigure it to anything that works for you -- the default might be conservative indeed. -Endre On Thu, Aug 7,

Re: [akka-user] Lost bytes with the akka stream TcpEcho example

2014-08-13 Thread Endre Varga
There is a bug in Akka Tcp which causes this. I dont remember the ticket No. but it is fixed and will be part of the next Akka bugfix release - then streams will be fixed at the next release. 2014.08.13. 7:37 ezt írta ("William Le Ferrand" ): > Dear List, > > I've facing a puzzling issue with (a s

Re: [akka-user] How to split an inbound stream on a delimiter character using Akka Streams

2014-09-03 Thread Endre Varga
Hi Chris, Casting the ByteString to a stream of Bytes is very ineffective. I would go with a stream of ByteStrings (chunks) instead. In these cases a Transformer step is the best option, buffering up chunks as much as it is needed and then emitting as much lines as you parsed. Btw, there is a dor

Re: [akka-user] How to split an inbound stream on a delimiter character using Akka Streams

2014-09-03 Thread Endre Varga
Once caveat with Viktor's example is that it keeps the original input chunk boundaries, so if you have chunks "Hel" "lo Wor" "ld!" Then the ouput would be "Hel" "lo" "Wor" "ld!" but not "Hello" "World!" I don't know if this is what you want or not. -Endre On Wed, Sep 3, 2014 at 2:42 PM

Re: [akka-user] Akka-http

2014-09-09 Thread Endre Varga
Hi Karthik, > *def output = > Source.fromFile("C:\\Users\\karthik\\Downloads\\big_buck_bunny.mp4")(scala.io.Codec.ISO8859)* > Using Source here will be horribly inefficient. > > > *def video = HttpResponse(entity = > HttpEntity.Chunked(MediaTypes.`video/mp4`, Flow(output.map(_.toByte).map(a >

Re: [akka-user] Using Scheduler vs deadline to mimic some backend: scheduler is slow(er)

2014-09-15 Thread Endre Varga
> kes aprox 60ms and using the scheduler we saw that it was 80ms we tried >> the deadline. >> > > Scheduler is not optimized for high precision timers, it is optimized for low overhead scheduling of a large number of timers. It also ensures that it does not fire early, but might fire later. By defa

Re: [akka-user] sort merge reactive streams

2014-09-24 Thread Endre Varga
There will be all kinds of merges available in the future. Akka Streams is still a preview so we change stuff all the time. To get to the point where we can support pluggable merges we needed the graph API and support for n-way fan-in operations first. So stay tuned :) -Endre On Wed, Sep 24, 2014

Re: [akka-user] Akka stream compression / decompression

2014-10-08 Thread Endre Varga
Do you properly close/flush the outputstream? -Endre On Wed, Oct 8, 2014 at 3:45 PM, Nicolas Jozwiak wrote: > I've just tried with a smaller chunk size (1000), and now I have a > different file size at the end => (Expected file length: '114541', actual: > '95541') > Weird... > > Nicolas > > Le

Re: [akka-user] Akka stream compression / decompression

2014-10-08 Thread Endre Varga
Nicolas, I am not sure the code you wrote does what you want. First of all reading something in byte-by-byte is highly inefficient, you should have your source as a stream of blocks, for example Source[ByteString]. The .grouped() will not help at all, because now you will get Seq[Byte] which means

Re: [akka-user] Dedicated Cluster Dispatcher not involved

2014-10-09 Thread Endre Varga
> > * "use-dispatcher" : "cluster-dispatcher"* > That should be "akka.cluster.cluster-dispatcher", you have to reference dispatchers by their full path. By the way, you also seem to have this strange nesting of cluster.akka.cluster.etc, which looks wrong. -Endre > } >

Re: [akka-user] Re: Dedicated Cluster Dispatcher not involved

2014-10-10 Thread Endre Varga
> > Any other ideas? > The same: you are providing the wrong path to the dispatcher configuration. Configuration elements are nested, and correspond to paths. To set the dispatcher any of the following works: akka.cluster.use-dispatcher = or akka.cluster { use-dispatcher = } or akka { c

Re: [akka-user] [akka-stream] Understanding conflate and zip

2014-10-17 Thread Endre Varga
On Thu, Oct 16, 2014 at 10:49 AM, Alec Zorab wrote: > I think this is a very common use case for applications streaming time > sensitive data (for example prices) where we would want to do an n-way zip > and then receive the most recent set of data for those n things. > I agree, and it is also u

Re: [akka-user] Unrecoverable "gated" state in remote system

2014-11-06 Thread Endre Varga
Hi Robert, On Wed, Nov 5, 2014 at 9:55 PM, Robert Preissl wrote: > hello! > > I am having a problem in my remote Akka production system, which consists > of 3 nodes running with the latest version of Akka (2.3.6.): > > In more details, I am experiencing errors with "*rolling restarts*" of > the

Re: [akka-user] akka http+streams applying TCP backpressure

2014-11-25 Thread Endre Varga
Hi, On Tue, Nov 25, 2014 at 5:05 PM, Joe Edwards wrote: > From the original announcement ( > http://typesafe.com/blog/typesafe-announces-akka-streams) it sounds as > though the HTTP entity stream should [have the ability to] apply TCP > back-pressure to clients streaming into the server. > > A

Re: [akka-user] akka http+streams applying TCP backpressure

2014-11-26 Thread Endre Varga
Hi Joe, There is a configuration section for the underlying IO stuff: # The maximum number of bytes delivered by a `Received` message. Before # more data is read from the network the connection actor will try to # do other work. akka.io.tcp.max-received-message-size = unlimited (see http

Re: [akka-user] Re: [ANNOUNCE] Akka Streams & HTTP 1.0 MILESTONE 1

2014-12-08 Thread Endre Varga
On Sat, Dec 6, 2014 at 2:40 PM, Muki wrote: > Nice work! I tried it and was wondering if the usage of *Stage* and > *Directive* is correct > > *class* GridCellTransformer(*implicit* *val* resolution: Double) *extends* > PushStage[LocationUpdate, IndexedLocationUpdate] { > > *override* *def* onP

Re: [akka-user] Re: [ANNOUNCE] Akka Streams & HTTP 1.0 MILESTONE 1

2014-12-08 Thread Endre Varga
. In fact the Directive types only exist compile time, since the context, under the hood will return null every time. The types are just a nice way to enforce that it must be called, an not every time is allowed to call every method. -Endre > On 8 Dec 2014 08:44, "Endre Varga" wrote:

Re: [akka-user] Akka HTTP client closing connection early

2014-12-08 Thread Endre Varga
On Mon, Dec 8, 2014 at 3:08 PM, Roland Kuhn wrote: > Which server do you see this with? A priori it makes sense to close the > sending side if no further requests will follow, but if relevant HTTP > servers misinterpret this then we’ll have to fix it (whether or not it is > broken is a different

Re: [akka-user] sort merge reactive streams

2014-12-10 Thread Endre Varga
AM, √iktor Ҡlang > wrote: > >> +1 >> >> On Wed, Sep 24, 2014 at 5:07 AM, Endre Varga >> wrote: >> >>> There will be all kinds of merges available in the future. Akka Streams >>> is still a preview so we change stuff all the time. To get to

Re: [akka-user] akka.remote.transport.Transport$InvalidAssociationException: connection timed out while I can telnet the remote port

2014-12-10 Thread Endre Varga
I guess this is exactly being fixed right now: https://github.com/akka/akka/issues/16505 -Endre On Wed, Dec 10, 2014 at 1:39 PM, √iktor Ҡlang wrote: > Hi Jason, > > always, always, give us what versions you are using. > This saves both of us time, so please do this. Thanks! > > On Wed, Dec 10,

Re: [akka-user] A little problem with new HTTP 1.0-M1

2014-12-24 Thread Endre Varga
Hi Greg, On Tue, Dec 23, 2014 at 10:57 PM, tigerfoot wrote: > Thanks for the clarification... the new API is very different. I need to >> let this whole flows thing sink in a bit, but I kinda see where its going. >> > Take a look at the new docs: http://doc.akka.io/docs/akka-stream-and-http-ex

Re: [akka-user] Akka HTTP outgoing connections always initialized in GraphFlows

2014-12-24 Thread Endre Varga
Hi Magnus, On Wed, Dec 24, 2014 at 1:55 AM, Magnus Andersson < magnus.anders...@mollyware.se> wrote: > Hi > > I am building a simple reverse proxy as an exercise to understand Akka > Streams. I have read the new docs but could not find an answer. > > I'm using FlexiRoute as recommended in an ea

Re: [akka-user] Getting strange error 2.4-Snapshot with stream+http 1.0-M2

2015-01-07 Thread Endre Varga
Hi, Streams is compiled against Akka 2.3.x which is not guaranteed to be binary compatible with 2.4. I expect that the above code to work with Akka 2.3.x. (if not, then this is a bug) -Endre On Wed, Jan 7, 2015 at 4:40 AM, tigerfoot wrote: > Hello, > > I've got this code: > > def httpGet( uri:

Re: [akka-user] Not loosing message due to remote actor unavailable.

2015-01-09 Thread Endre Varga
Hi, On Fri, Jan 9, 2015 at 4:12 PM, Matan Safriel wrote: > Thanks Patrik, good to know, because the cluster module may seem like a > very specific and rather unfinished reference implementation; > What do you mean by unfinished reference implementation? It is a fully supported module of Akka.

Re: [akka-user] Not loosing message due to remote actor unavailable.

2015-01-09 Thread Endre Varga
sure that each seed also knows of at least one other, remember, the goal is to avoid a chicken-and-egg scenario and provide an avenue for all nodes in the cluster to discover one another." -Endre > > Maybe this should be a different thread. > > On Fri, Jan 9, 2015 at 5:15 PM, Endr

Re: [akka-user] Re: How to Properly Manage Akka's Memory Usage with 40 Million Lines Task?

2015-01-10 Thread Endre Varga
Hi, On Fri, Jan 9, 2015 at 10:53 PM, Allen Nie wrote: > Hey Viktor, > > I'm trying to use Akka to parallelize this process. There shouldn't be > any bottleneck, and I don't understand why I got memory overflow with my > first version (actor version). The main task is to read in a line, break

Re: [akka-user] Re: Sharing message queue between two akka actors?

2015-01-12 Thread Endre Varga
On Mon, Jan 12, 2015 at 5:38 AM, Krishna Kadam wrote: > > > Hi all, >> > Thanks for your valuable guidance, But I am bit confused with the answer > to first question. In what circumstances I should share the message queue > in between two actors and In what circumstances should I not share the >

Re: [akka-user] Re: ResendUnfulfillableException in remoting

2015-01-14 Thread Endre Varga
Hi Jim, We are aware of the issue, a fix is being prepared: https://github.com/akka/akka/pull/16640 -Endre On Wed, Jan 14, 2015 at 2:24 AM, Jim Newsham wrote: > > P.S. I've checked the release notes and didn't see anything specifically > related to ResendUnfulfillableException, although some

Re: [akka-user] Re: UnboundedPriorityMailbox breaks message ordering?

2015-01-14 Thread Endre Varga
On Fri, Jan 9, 2015 at 10:02 PM, Viktor Klang wrote: > > > On Fri, Jan 9, 2015 at 9:40 PM, David Hotham > wrote: > >> Of course it's normal and expected that a PriorityQueue returns equal >> priority elements in arbitrary order. That's just how heaps work. However >> that doesn't imply that a

Re: [akka-user] Akka Cluster and Persistence Consistency

2015-01-14 Thread Endre Varga
On Wed, Jan 14, 2015 at 5:02 PM, Akka Team wrote: > Hi Oleg, > Your understanding of both topics, in the current version of Akka, are > correct. > More specifically: > > Is it possible to configure Akka Cluster with auto-downing so that with >> 100% probability at each moment at most one cluster

Re: [akka-user] [akka-streams] FlexiMerge completion handling

2015-01-16 Thread Endre Varga
Hi Carsten, If you express that you want to read ALL inputs, then you implicitly also expressed that you want to be completed when ANY of the inputs are completed (otherwise you cannot get ALL, so it would be a deadlock). The default completion handling is invoked on completion, but its onComplet

Re: [akka-user] [akka-stream] Stages unit testing

2015-01-20 Thread Endre Varga
Hi, On Mon, Jan 19, 2015 at 5:54 PM, Alexey Romanchuk < alexey.romanc...@gmail.com> wrote: > Hey hakkers! > > I am currently updating old application built on akka-streams 0.4 to > 1.0-MX API. I used Transformers and now migrate it to PullPushStages. In > general migration is pretty easy, but I

Re: [akka-user] Re: Feedback on Akka Streams 1.0-M2 Documentation

2015-01-21 Thread Endre Varga
Hi Sam, On Tue, Jan 20, 2015 at 9:56 PM, Sam Halliday wrote: > One more comment on the streams API. It is really cool that you've thought > about using mapConcat instead of flatMap to enable optimised merge > operations. I just wanted to draw your attention to a clojure project that > does super

Re: [akka-user] Feedback on Akka Streams 1.0-M2 Documentation

2015-01-21 Thread Endre Varga
Hi Sam, > Bjorn asked if I felt any examples were missing, and sadly my > original request (that I've been going on about for years, > sorry!) is indeed missing. It is the case of a fast producer and > a slow consumer that is ideal for parallelisation. > There are many examples of slow consumer

Re: [akka-user] Re: Feedback on Akka Streams 1.0-M2 Documentation

2015-01-21 Thread Endre Varga
and a function T => Seq[U] and gives a Source[U] (similarly with Flow). Source is not a Seq, it is a completely different beast. > On 21 Jan 2015 08:03, "Endre Varga" wrote: > >> Hi Sam, >> >> On Tue, Jan 20, 2015 at 9:56 PM, Sam Halliday >> wrote: >&g

Re: [akka-user] Re: Feedback on Akka Streams 1.0-M2 Documentation

2015-01-21 Thread Endre Varga
-Endre > Anyway, it is a side point and I don't want to get derailed from my > original questions so I will read your other responses later today. > On 21 Jan 2015 08:50, "Endre Varga" wrote: > >> >> >> On Wed, Jan 21, 2015 at 9:45 AM, Sam Halliday >>

Re: [akka-user] Cluster unreachable and a lot of cluster connections

2015-01-21 Thread Endre Varga
Hi Johannes, We just released 2.3.9 with important bugfixes. I recommend to update and see if the problem is still persisting. -Endre On Wed, Jan 21, 2015 at 10:29 AM, Johannes Berg wrote: > Many connections seem to be formed in the case when the node has been > marked down for unreachability

Re: [akka-user] Cluster unreachable and a lot of cluster connections

2015-01-21 Thread Endre Varga
Hi Johannes, See the milestone here: https://github.com/akka/akka/issues?q=milestone%3A2.3.9+is%3Aclosed The tickets cross reference the PRs, too, so you can look at the code changes. The issue that probably hit you is https://github.com/akka/akka/issues/16623 which manifested as system message d

Re: [akka-user] [akka-stream] Decrease buffer size for some stages

2015-01-22 Thread Endre Varga
Hi Alexey, On Thu, Jan 22, 2015 at 4:15 AM, Alexey Romanchuk < alexey.romanc...@gmail.com> wrote: > Hey! > > I have a stream that process incoming messages, assemble big message > "pack" and send it to other system via network. Incoming messages are > relatively small and I use big buffers to i

Re: [akka-user] [akka streams] question on some time related use cases

2015-01-22 Thread Endre Varga
Hi Frank, On Thu, Jan 22, 2015 at 2:51 AM, Frank Sauer wrote: > Thanks, I came up with the following, but I have some questions: > > /** >* Holds elements of type A for a given finite duration after a > predicate p first yields true and as long as subsequent >* elements matching that fir

Re: [akka-user] [akka streams] question on some time related use cases

2015-01-22 Thread Endre Varga
On Thu, Jan 22, 2015 at 5:07 AM, Frank Sauer wrote: > Update, in a simple test scenario like so > > val ticks = Source(1 second, 1 second, () => "Hello") > > val flow = ticks.transform(() => new FilterFor[String](10 seconds)(x => > true)).to(Sink.foreach(println(_))) > > flow.run() > > I'm

Re: [akka-user] [akka-stream] Decrease buffer size for some stages

2015-01-22 Thread Endre Varga
Hi Alexey, On Thu, Jan 22, 2015 at 12:31 PM, Alexey Romanchuk < alexey.romanc...@gmail.com> wrote: > It is exactly what I have tried to achieve! You guys did amazing work with > all akka streams. Thanks! :) > You might be also interested in this ticket: https://github.com/akka/akka/issues/16610

Re: [akka-user] Cluster unreachable and a lot of cluster connections

2015-01-22 Thread Endre Varga
Without detailed logs I cannot say. If there would be a system message buffer overflow then it would cry loudly in the logs. Also it says that an unreachable node is being removed, so there should be events happening before unreachability. This might be something completely else. The full config wo

Re: [akka-user] Cluster unreachable and a lot of cluster connections

2015-01-22 Thread Endre Varga
Hi Johannes, On Thu, Jan 22, 2015 at 4:53 PM, Johannes Berg wrote: > > I will try that but it seems that will only help to a certain point and > when I push the load further it will hit it again. > There is no system message traffic between two Akka systems by default, to have a system send sys

Re: [akka-user] Akka-Http: How to connect a Route with an IncomingConnection?

2015-01-22 Thread Endre Varga
Hi, Philippe, On Thu, Jan 22, 2015 at 6:28 PM, Philippe Milot wrote: > So I'm following the documentation on the new Akka-Http experimental > modules, and I'm trying to get a basic Hello World using the Routing DSL. > > I've defined my route as follows: > > val route: Route = { > complete(

Re: [akka-user] Re: [akka-stream] Junctions documentation and specs

2015-01-23 Thread Endre Varga
On Fri, Jan 23, 2015 at 7:02 AM, Alexey Romanchuk < alexey.romanc...@gmail.com> wrote: > Hey! > > Also there is not straightforward how backpressure works with Broadcast. > What if one of the outputs is busy and another one is requesting for for > new elements? > It will backpressure and adapt th

Re: [akka-user] [akka-stream] Periodic source of sources

2015-01-23 Thread Endre Varga
On Fri, Jan 23, 2015 at 5:45 PM, Martynas Mickevičius < martynas.mickevic...@typesafe.com> wrote: > There was a discussion on a similar but not completely exact topic that > you described here . > umm, no, that is slightly different if I understood the p

Re: [akka-user] TCP Outgoing Connection Lifecycle

2015-01-23 Thread Endre Varga
Hi Cole, The connection disconnect event will be signalled as stream completion to the reading stream and cancellation to the writing stream. For example if you fold over the ouput stream of the TCP connection, on TCP closure (assuming normal close event) the fold element will emit the final resul

Re: [akka-user] Feedback on Akka Streams 1.0-M2 Documentation

2015-01-23 Thread Endre Varga
Hi Sam, On Fri, Jan 23, 2015 at 12:02 AM, Sam Halliday wrote: > On Wednesday, 21 January 2015 08:21:15 UTC, drewhk wrote: > >> I believe it may be possible to use the current 1.0-M2 to address > >> my bugbear by using the Actor integration to write an actor that > >> has N instances behind a rou

Re: [akka-user] Cluster unreachable and a lot of cluster connections

2015-01-25 Thread Endre Varga
Hi Johannes, On Fri, Jan 23, 2015 at 8:39 AM, Johannes Berg wrote: > Thanks for the answers, this really explains a lot. I will go back to my > abyss and rethink some things. See below some answers/comments. > > On Thursday, January 22, 2015 at 6:31:01 PM UTC+2, drewhk wrote: >> >> Hi Johannes,

Re: [akka-user] Akka HTTP - back-pressure on incoming connections

2015-01-26 Thread Endre Varga
Hi Jean, On Mon, Jan 26, 2015 at 9:03 AM, Jean Rossier wrote: > Hello, > > I'm wondering if there is a way to use back-pressure mechanism on incoming > connections with Akka HTTP ? > The documentation mentions clearly that there is no back-pressure applied > to the connections Source if we use t

Re: [akka-user] TCP Outgoing Connection Lifecycle

2015-01-26 Thread Endre Varga
Hi Cole, On Fri, Jan 23, 2015 at 11:11 PM, wrote: > Hey Endre, > > Thanks for the response but I don't quite understand how to implement what > you're suggesting. > I didn't suggest anything, I just gave an example how stream completion and cancellation work, using Fold as the example operati

Re: [akka-user] akka http 1.0-M2 thread pegs a CPU core until connection closes on Windows

2015-01-27 Thread Endre Varga
Hi, There is a setting akka.io.tcp.windows-connection-abort-workaround-enabled setting that is known to be causing this. It is a workaround for Windows to get connection abort events reliably, but unfortunately has this side-effect. You can disable the workaround from the config, currently it is a

Re: [akka-user] [Akka-2.3.7][Scala] - akka.remote.EndpointWriter

2015-01-27 Thread Endre Varga
Hi Yarden, On Tue, Jan 27, 2015 at 9:58 AM, Yarden Bar wrote: > Hi > Thanks for the SUPER fast reply. > > I'll upgrade as you suggested. > The upgrade will not change the message though. This is a status message that is useful to debug if you send remote messages much faster than the network ca

Re: [akka-user] TCP Stream and Request Strategy

2015-01-27 Thread Endre Varga
On Tue, Jan 27, 2015 at 1:35 PM, Björn Antonsson < bjorn.antons...@typesafe.com> wrote: > Hi Thomas, > > There is a recipe for chunking up bytestrings in the stream docs > http://doc.akka.io/docs/akka-stream-and-http-experimental/1.0-M2/scala/stream-cookbook.html#Chunking_up_a_stream_of_ByteString

Re: [akka-user] TCP Stream and Request Strategy

2015-01-27 Thread Endre Varga
Hi Thomas, On Tue, Jan 27, 2015 at 3:32 PM, Thomas Zimmer wrote: > Thank you so much guys! You definitely rock :) > > I think Björn link was excatly what I was loooking for. Is there a way to > influence the demanded chunk-size dynamically? > No, the ByteStrings are of arbitrary size. You need

Re: [akka-user] tcp client server recommendations

2015-02-02 Thread Endre Varga
On Sun, Feb 1, 2015 at 9:05 PM, Jeremy Stone wrote: > Would something like the following in the server handler do it for you?... > > def silentSource = ??? // Source that emits nothing but does never > completes > def handleDataFromClient: ByteString => Unit = ??? > > ForeachSink[Stre

Re: [akka-user] Re: Implementing at-least-once ingestion pipeline with Akka streams

2015-02-02 Thread Endre Varga
Hi Evan, As we progress we make more and more things possible, we will keep this use-case in mind. -Endre On Sat, Jan 31, 2015 at 2:52 AM, Evan Chan wrote: > Thanks Bjorn. > > On Fri, Jan 30, 2015 at 2:33 AM, Björn Antonsson < > bjorn.antons...@typesafe.com> wrote: > >> Hi Evan, >> >> I don't

Re: [akka-user] Akka Stream: How to dynamically group elements?

2015-02-02 Thread Endre Varga
On Mon, Feb 2, 2015 at 6:49 PM, Akka Team wrote: > Hi Elmar, > > > > On Mon, Feb 2, 2015 at 6:40 PM, Elmar Weber wrote: > >> I am looking to batch elements in a flow in a non-standard way and >> sending them off. >> A typical flow for this based on a static count would look like this: >> >> Sour

Re: [akka-user] akka.stream.scaladsl.Flow and flatMap

2015-02-08 Thread Endre Varga
Hi, There is a flatMap, it is just not called that. There is a flatten() method that takes a strategy, currently the only one being concat: flatten(FlattenStrategy.concat). The reason for that we don't provide a method called flatMap is to avoid it being overused in for comprehensions. In the land

Re: [akka-user] Akka-streams - when second source being concatenated fails, first is not consumed

2015-02-11 Thread Endre Varga
Hi Jakub, > Source(List(0,1,2)).map { i => > if (i != 2) > Source(List(0)) > else > Source(throwable) > }.flatten(FlattenStrategy.concat).runForeach(println) > > > 0 > 0 > > > But this one doesn't yield anything, as if the condition was (i != 0). Is > there a way to solve it? > Str

Re: [akka-user] Grokking akka-stream and TcpStream

2015-02-13 Thread Endre Varga
Hi Reid, On Thu, Feb 12, 2015 at 5:56 PM, Reid Spencer wrote: > hAkkers, > > I've been unable to *grok * how to > communicate with a TCP socket using akka-stream and StreamTcp extension. > At this point, I'm not sure the fault is entirely mine. :) > I can unde

Re: [akka-user] Grokking akka-stream and TcpStream

2015-02-13 Thread Endre Varga
Hi Reid, On Fri, Feb 13, 2015 at 11:59 AM, Reid Spencer wrote: > Hi Eric, > > Thanks for your response. It is a little comforting to know that I’m not > the only one on this planet also struggling with how to do something real > with akka-stream. I’m sure this thread will eventually lead to the

Re: [akka-user] Grokking akka-stream and TcpStream

2015-02-13 Thread Endre Varga
Hi Reid, > yout) with exactly one input and output port that is not wired to anything. > > > Okay, just to be clear, GraphBackedFlow will be gone as will the > Flow.apply method that creates them ? > GraphBackedFlow will be gone, but the functionality will be there, so you will still be able to c

Re: [akka-user] Re: Confusing problem whilst testing a PushPullStage implementation of a sliding window

2015-02-16 Thread Endre Varga
Hi, The problem is really simple. You request sub.request(msgs.length) from the Window element, and then you send elements to it: for (msg <- msgs) { pub.sendNext(msg) } The problem here is your underlying assumption is that if you request X elements from a Processor (which is what the Windowe

Re: [akka-user] Re: Confusing problem whilst testing a PushPullStage implementation of a sliding window

2015-02-16 Thread Endre Varga
On Mon, Feb 16, 2015 at 11:50 AM, Endre Varga wrote: > Hi, > > The problem is really simple. You request sub.request(msgs.length) from > the Window element, and then you send elements to it: > > for (msg <- msgs) { > pub.sendNext(msg) > } > > The problem here

Re: [akka-user] Re: Confusing problem whilst testing a PushPullStage implementation of a sliding window

2015-02-16 Thread Endre Varga
On Mon, Feb 16, 2015 at 1:24 PM, Carl Pulley wrote: > Thanks for that (and the AutoPublisher hint). It was a great help in > seeing what I was misunderstanding! > Let's hope so :) If it does not work, then we have a bug, but thankfully we also will have a reproducer ;) -Endre > > Carl. > >

Re: [akka-user] Re: streams - Source that emits only 1 (or no) element

2015-02-17 Thread Endre Varga
HI Giovanni, On Mon, Feb 16, 2015 at 11:31 PM, Giovanni Alberto Caporaletti < paradi...@gmail.com> wrote: > You're absolutely right about the future not representing an "already > running computation". But it's not a "blueprint". If a see a future, I take > for granted that something will happen

Re: [akka-user] 'Graph must be connected' with Flow created from Publisher+Subscriber actor.

2015-02-18 Thread Endre Varga
Hi, On Wed, Feb 18, 2015 at 6:27 PM, folex <0xd...@gmail.com> wrote: > class ActorPubSub extends ActorSubscriber with ActorPublisher[Int] { > var events = Seq.empty[Int] > > override protected def requestStrategy: RequestStrategy = > OneByOneRequestStrategy > override def receive: Actor.

Re: [akka-user] Re: Confusing problem whilst testing a PushPullStage implementation of a sliding window

2015-02-19 Thread Endre Varga
Hi Wolfgang, On Thu, Feb 19, 2015 at 3:24 PM, Wolfgang Friedl < wolfgang.fri...@hotmail.com> wrote: > Hi togehter! > > I observed the same exception ( Input buffer overrun) on my side today. > Even so I read this task I'm not sure if I got it right. > > I do have a Flow were I put some "processi

Re: [akka-user] Re: Confusing problem whilst testing a PushPullStage implementation of a sliding window

2015-02-19 Thread Endre Varga
Hi Wolfgang, On Thu, Feb 19, 2015 at 4:47 PM, Wolfgang Friedl < wolfgang.fri...@hotmail.com> wrote: > There is one thing which came int to my mind. > > We are using mapConcat which does have the signature (f: Out ⇒ > immutable.Seq[T]) > > Could it be that in a case were more elements are publis

Re: [akka-user] Re: Confusing problem whilst testing a PushPullStage implementation of a sliding window

2015-02-20 Thread Endre Varga
Hi Wolfgang, On Thu, Feb 19, 2015 at 7:35 PM, Wolfgang Friedl < wolfgang.fri...@hotmail.com> wrote: > Hi Endre > > My publisher is quite simple! It is an actor (extending the > ActorPublisher) waiting for incoming messages. He puts the messages in the > buffer if the totaldemand is > 0 I call onN

Re: [akka-user] akka-streams - How to define a Source from an arbitrary event stream?

2015-02-20 Thread Endre Varga
Hi Simon, One trick I like to use is to define a Source in terms of a PushPullStage. Now this sounds strange, since a PushPullStage is supposed to be someting that transforms incoming element into outgoing elements, how can that be a Source? Well, the trick is this: def mySource = Source.empty

Re: [akka-user] OutOfMemoryError on outgoing remote messages

2014-02-24 Thread Endre Varga
Hi Arjun, On Mon, Feb 24, 2014 at 5:36 PM, Arjun Panday wrote: > Hi, > > Sorry for the confusion, I made my message a bit too concise: Indeed, the > workers start by sending a "Ready" message and they Ack the work once it's > done, after which they start over with a new "Ready". > That is good

Re: [akka-user] is quarantining really necessary

2014-03-05 Thread Endre Varga
Hi Jim, That indeed sounds strange. Do you have some logs? -Endre On Wed, Mar 5, 2014 at 4:05 AM, Jim Newsham wrote: > > I am playing around with remoting, and now I'm confused because I > reconstructed a situation where remote deathwatch is triggered, and yet the > connection is able to be r

Re: [akka-user] is quarantining really necessary

2014-03-06 Thread Endre Varga
Thanks Jim, I will take a look at it. Quite probably a bug. -Endre On Thu, Mar 6, 2014 at 2:23 AM, Jim Newsham wrote: > > I cleaned up my test case a bit and I'm attaching it, as well as the logs > of one of the runs. Some quick notes: > > - EchoMain starts EchoActor. This actor just echoes

Re: [akka-user] Re: How can I reconcile untyped actors with typeful programming?

2014-03-09 Thread Endre Varga
Hi Daniel, The issue is that type systems are designed for local and not distributed computations. Let's look at an example. Imagine an actor that has three states, A, B and C In state A it accepts messages of type X, and when received one, it transitions to B In state B it accepts messages of t

Re: [akka-user] Re: How can I reconcile untyped actors with typeful programming?

2014-03-09 Thread Endre Varga
Hi Aleh, On Sun, Mar 9, 2014 at 6:56 PM, OlegYch wrote: > Endre, i don't think this is related to distributed computations at all. > Any method call can fail even locally. > This is true of course, but way more relevant in distributed cases where failures are orders of magnitudes more common.

Re: [akka-user] Re: How can I reconcile untyped actors with typeful programming?

2014-03-09 Thread Endre Varga
, separating actors into deployment sets is part of the > system design, needs careful planning, and doesn't change often. Inside > each local set, the benefits of guaranteed locality would be large > (messages aren't lost, static typing, etc.) > > > On Sun, Mar 9, 2014 at

Re: [akka-user] Some system returns unexpected from quarantine

2014-03-20 Thread Endre Varga
Hi Wofr, This is a bug, will be fixed in 2.3.1 very soon. You can follow the ticket here: https://www.assembla.com/spaces/akka/tickets/3943-gate-should-not-overwrite-quarantine#/activity/ticket : -Endre On Thu, Mar 20, 2014 at 10:19 AM, Wofr wrote: > Hi ! > > We use Akka 2.3.0. with the defau

Re: [akka-user] testing akka cluster on Blue Waters @ NCSA

2014-03-24 Thread Endre Varga
On Mon, Mar 24, 2014 at 8:30 AM, Patrik Nordwall wrote: > Hi Boris, > > Thanks for packing it in a reproducible sample. As Viktor points out the > Java serializer is one of the prime suspect for bottlenecks in remote > communication. Here you have found something that I think can be improved > in

Re: [akka-user] testing akka cluster on Blue Waters @ NCSA

2014-03-24 Thread Endre Varga
Hi Boris, Thank you for trying out! Patrik I think figured out the reason (described in the ticket). This is very much related to backpressure since the messages get piling up in the EndpointWriter which continuosly stashes and unstashes an ever growing amount of messages (gets to O(n^2) eventuall

Re: [akka-user] testing akka cluster on Blue Waters @ NCSA

2014-03-24 Thread Endre Varga
Hi Boris, On Mon, Mar 24, 2014 at 4:19 PM, Boris Capitanu wrote: > Thank you, Patrik. > > I think you hit the nail in the head with that ticket. I wanted to write > earlier that this felt like behavior you see when you have two nested "for" > loops: > > for i = N to 1 > for j = 1 to N >

Re: [akka-user] Move/Migrate Actors between Remote Nodes

2014-03-25 Thread Endre Varga
Of course I meant "To be able to migrate *stateful* actors". -Endre On Tue, Mar 25, 2014 at 4:48 PM, Akka Team wrote: > Hi Andreas, > > To be able to migrate actors you need to be able to restore their state at > their new place. This is one of the use-cases for the new experimental > akka-per

Re: [akka-user] multiple agents for maintaining mutable state between requests

2014-03-26 Thread Endre Varga
Hi, On Wed, Mar 26, 2014 at 3:15 PM, MV wrote: > Hi Andre, > > Thanks a lot for getting back to me. Yes your understanding of my problem > is correct. Can I google for more information on ConsistentHashingPool and > how to use it? > I will also look into CustomRouter and let you know how that w

Re: [akka-user] Cant send and receive other messages than Strings between AKKA actors

2014-04-29 Thread Endre Varga
Hi Matthias, On Tue, Apr 29, 2014 at 7:47 PM, Matthias Heininger < muenchn...@googlemail.com> wrote: > If try to run my application which uses akka it shows me the following > error: > > play.api.i18n.Messages$MessagesParser$$anon$1: Configuration error[`=' > expected but ` > ' found] >

Re: [akka-user] Recovery following node failure

2014-04-29 Thread Endre Varga
Hi George, On Tue, Apr 29, 2014 at 7:01 PM, George Wilk wrote: > Thanks, Patrik. > > I rebuilt my POC with akka release 2.3.2 and re-tested. I was able to > recreate the scenario with in-flight event not being replayed after JVM > crash. Here are some additional parameters and findings pertain

Re: [akka-user] Event re-distribution following actor/VM failure

2014-04-29 Thread Endre Varga
Hi George, On Tue, Apr 29, 2014 at 7:12 PM, George Wilk wrote: > This posting is somewhat related to my earlier topic titled “Recovery > following node failure”, which focused on replay of event following > processor failure due to VM crash. Even though this question is related to > the topic o

Re: [akka-user] quorum-based split brain resolution

2014-05-07 Thread Endre Varga
That is a really good summary, Roland. This should go into docs or at least a blog post? -Endre On Tue, May 6, 2014 at 8:28 PM, Akka Team wrote: > Hi Shikhar, > > thanks for sharing! > > There are many possible ways of dealing with partitions in a distributed > system, and it depends very much

Re: [akka-user] [akka-streams]: actor producers, load balancers

2014-05-26 Thread Endre Varga
Hi Adam > - is it reasonable (thinking about reactive streams in general) to have an > actor which produces elements on-demand (instead of providing a > collection/iterator/() => as is currently supported)? As far as I > understand the current implementation, subscribers explicitly ask > publishe

Re: [akka-user] Has problem to consume inputStream from StreamTcp

2014-05-30 Thread Endre Varga
Hi vincent, > after I run it, the log only have: > > [DEBUG] [05/28/2014 14:20:56.235] > [ClientAndServer-akka.actor.default-dispatcher-3] [akka.tcp:// > ClientAndServer@127.0.0.1:2551/system/IO-TCP/selectors/$a/0] Successfully > bound to /127.0.0.1:6000 > > Server started, listening on: /127.0.0

Re: [akka-user] [performance] akka with sync REST

2014-06-24 Thread Endre Varga
Just a sidenote, CPU usage can be very misleading when profiling things using the ForkJoinPool. Without a detalied profile, parameters and ways to reproduce, it is impossible to say anything meaningful here. -Endre On Tue, Jun 24, 2014 at 3:03 PM, √iktor Ҡlang wrote: > > > > On Tue, Jun 24, 20

Re: [akka-user] ̣̣[akka-stream] Looping or recusrion in Duct / Flow

2014-06-25 Thread Endre Varga
Hi Benoit On Wed, Jun 25, 2014 at 9:49 AM, benq wrote: > Hi All, > > Is it possible to feed a Duct (/Flow) with the elements it produces, like > a loop. > Looping this way is dangerous, in general it usually leads to element count explosion, but since streams are always bounded, you will very

Re: [akka-user] ̣̣[akka-stream] Looping or recusrion in Duct / Flow

2014-06-27 Thread Endre Varga
Hi Benoit, I wasn't proposing ActorProucer to loop back, instead you should encapsulate the scrollId state and corresponding behacior in that ActorProducer -- i.e. you implement your original snippet not in terms of flow, but inside the ActorProducer. Then you can compose that stream with others.

Re: [akka-user] ̣̣[akka-stream] Looping or recusrion in Duct / Flow

2014-06-27 Thread Endre Varga
On Fri, Jun 27, 2014 at 11:59 AM, benq wrote: > > > Le vendredi 27 juin 2014 10:01:57 UTC+2, drewhk a écrit : > >> Hi Benoit, >> >> I wasn't proposing ActorProucer to loop back, instead you should >> encapsulate the scrollId state and corresponding behacior in that >> ActorProducer -- i.e. you im

Re: [akka-user] ̣̣[akka-stream] Looping or recusrion in Duct / Flow

2014-06-27 Thread Endre Varga
On Fri, Jun 27, 2014 at 12:23 PM, Endre Varga wrote: > > > > On Fri, Jun 27, 2014 at 11:59 AM, benq wrote: > >> >> >> Le vendredi 27 juin 2014 10:01:57 UTC+2, drewhk a écrit : >> >>> Hi Benoit, >>> >>> I wasn't proposing Act

Re: [akka-user] streams: Multiple subscriptions need to delay producer to read from start?

2014-06-30 Thread Endre Varga
Hi Ferdinand, You can use a Duct instead of a Flow. Duct has an unbound input side, so you can call build() at the end to get a (Cosumer, Producer) pair. At this point no elements are flowing yet, so you can attach as many Consumers to the Producer end of the Duct as you want. After you are done,

Re: [akka-user] Re: ANNOUNCE: First akka-http-core preview and updated akka-stream preview

2014-07-07 Thread Endre Varga
Hi Alan, Akka-http works together with akka-stream, so it does work differently than you tried. Since this is an early technical preview the docs are quite a bit sketchy, but there are some examples already here: http://doc.akka.io/docs/akka-stream-and-http-experimental/0.4/scala/http-core-server.

Re: [akka-user] How to run akka stream distributedly in a cluster?

2014-07-14 Thread Endre Varga
HI Sean, > I come from bigdata background. > In my opinion, the Flow DSL is not expressive for many cases, like data > shuffle. Have you considered using DSL like the one used in cascading, or > spark, or storm trident? > The primary goal for streams is to provide a unified way to handle backpre

Re: [akka-user] Akka-Streams - async processors yielding multiple messages

2014-07-16 Thread Endre Varga
Hi! On Wed, Jul 16, 2014 at 10:49 AM, schoefts wrote: > Hi everyone, > > we are currently integrating Akka-Streams in an application. > > Looking at the current Flow DSL/API, I can see that Transformers > (Flow#transform) allow to *synchronously* produce a number of > output-messages from 1 mes

  1   2   3   4   5   >