Re: [akka-user] Why does Flow.mapConcat() need an Iterable, vs. an Iterator?

2017-09-26 Thread Bwmat
The functor already can return a separate Iterable per-invocation, unless I misunderstood your comment? To clarify, I meant, does the implementation of the http://doc.akka.io/japi/akka/current/akka/stream/javadsl/Flow.html#mapConcat-akka.japi.function.Function- stage ever need to obtain

Re: [akka-user] Why does Flow.mapConcat() need an Iterable, vs. an Iterator?

2017-09-26 Thread Konrad “ktoso” Malawski
Are multiple iterators ever needed to be requested from it? I'm kind of tempted to do Flow.create().mapConcat(iter -> new Iterable() { @Override public Iterator iterator() { return iter; }}).grouped(chunkSize).map(list ->

Re: [akka-user] Anyone can take a look at http://doc.akka.io/ ? it is down

2017-09-26 Thread Konrad “ktoso” Malawski
Thanks for reporting (and numerous others via twitter ;-)). We’re aware of the issue, and have fixed it for now. We’ll investigate some more though. The vm hosting the docs got corrupted and stopped being able to serve the docs. — Konrad `kto.so` Malawski Akka @ Lightbend

[akka-user] Re: akka-cluster workarounds for not being able to re-join cluster without restart?

2017-09-26 Thread Enrique Ell Pereira
Hi Chad, As far as I understand you have to restart the ActorSystem, not the process as you mentioned, to allow the ActorSystem to rejoin again the node. I would try to create a actor to shutdown it gracefully, wait until it goes down then restart/create the ActorSystem. Regards, Enrique

[akka-user] Anyone can take a look at http://doc.akka.io/ ? it is down

2017-09-26 Thread Jing Xiao
It has been down for a while. -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >> http://doc.akka.io/docs/akka/current/additional/faq.html >> Search the archives: https://groups.google.com/group/akka-user --- You received this message

[akka-user] Alpakka sink write only 1 file with all content

2017-09-26 Thread vianel
Hi! Using alpakka sinks for s3 or ftp, i need to upload multiple files but it seems the s3 sink and ftp sink just upload 1 file with all the contents inside this is one of my sinks: def storeToPath(path: String, fileName: String, settings: SftpSettings, append: Boolean): Sink[ByteString,

[akka-user] Why does Flow.mapConcat() need an Iterable, vs. an Iterator?

2017-09-26 Thread Bwmat
I'm talking about http://doc.akka.io/japi/akka/current/akka/stream/javadsl/Flow.html#mapConcat-akka.japi.function.Function- I had a flow that was emitting Iterator, and I wanted a step to 'chunk' the values to a given chunk size N (in other words, every iterator returned by the 'chunker' would

[akka-user] akka-cluster workarounds for not being able to re-join cluster without restart?

2017-09-26 Thread Chad Selph
We're currently using akka for a variety of things, and are starting some experiments with akka-cluster, but we've hit one roadblock. >From the documentation on akka-cluster membership lifecycle (http://doc.akka.io/docs/akka/2.5.4/scala/common/cluster.html#membership-lifecycle) : the actor

[akka-user] Re: Materialize future after content negotiation

2017-09-26 Thread johannes . rudolph
Oops, one should read the whole question before answering... Just saw that you already tried that. Unfortunately, it seems that this is indeed a shortcoming of the current model. I guess with a bit of fiddling you could try making all of those marshallers marshal to `Future[HttpResponse]`

[akka-user] Re: Materialize future after content negotiation

2017-09-26 Thread johannes . rudolph
Hi Mantis, you are right, `Marshaller.withFixedContentType` is a bit restricted in that regard. Fortunately, it is only a shortcut for simpler cases and the full asynchronous functionality is available for marshallers. Try something like Marshaller[Iterator[Data], HttpResponse] { implicit ec

Re: [akka-user] Re: Akka Http memory leak suspect

2017-09-26 Thread Bartosz Jankiewicz
I have verified that but there are 2 places where declare the materializers. Both are declared as vals. I will verify the number of materializer instances on my heap-dump to confirm. On Tue, 26 Sep 2017 at 13:24 Johannes Rudolph < johannes.rudo...@lightbend.com> wrote: > On Tue, Sep 26, 2017 at

Re: [akka-user] Re: Akka Http memory leak suspect

2017-09-26 Thread Johannes Rudolph
On Tue, Sep 26, 2017 at 7:18 AM, Patrik Nordwall wrote: > If the names are StreamSupervisor- I think it can be that a new > Materializer is created for each request. I don’t know if that is done by > your application or by Akka Http. Does that ring any bells? Do you

Re: [akka-user] PersistentFSM and event tags

2017-09-26 Thread t . ferrauto
On Monday, September 25, 2017 at 7:57:01 AM UTC+2, Patrik Nordwall wrote: > > Event adapter is the recommended way to add tags, to keep the logic in the > actor free from this event consuming aspect. Thank you for the answer. The problem I have with tagging in an *EventAdapter* is that I need

Re: [akka-user] Stopping of PersistentActor

2017-09-26 Thread Yaroslav Klymko
Oh indeed, looks like that is a bad example. Using custom messages will make sure `handler` passed to `persistAll` is executed. Thanks. On Tuesday, September 26, 2017 at 11:33:46 AM UTC+2, Konrad Malawski wrote: > > Sure Konrad, that's more like an example. > > The example is very specific, and

Re: [akka-user] Stopping of PersistentActor

2017-09-26 Thread Konrad “ktoso” Malawski
Sure Konrad, that's more like an example. The example is very specific, and not the recommended way. But even using own custom message and then calling context.stop will give similar effect. No, it’s different since it’s not an auto handled message. You can do whatever you want in response to

Re: [akka-user] Stopping of PersistentActor

2017-09-26 Thread Yaroslav Klymko
Sure Konrad, that's more like an example. But even using own custom message and then calling context.stop will give similar effect. Looks like there is no standard mechanism to stop actor gracefully without loosing side effects. On Tuesday, September 26, 2017 at 10:53:56 AM UTC+2, Konrad

[akka-user] "Event driven workflow engine" in Akka - any experiences?

2017-09-26 Thread Bertil Muth
Hi everybody. I am quite new to Akka and already fascinated. Now I am thinking of creating an extension to my own project to enable it to be distributed. The idea is to have a kind of "Workflow Engine" that is event driven. So basically: receive an event from a user, and if a condition is

Re: [akka-user] Stopping of PersistentActor

2017-09-26 Thread Konrad “ktoso” Malawski
Don’t use PoisonPill, but your protocol level messages to signal “plz stop”, which is best practice anyway, — Konrad `kto.so` Malawski Akka @ Lightbend On 26 September 2017 at 17:25:43, Yaroslav Klymko (t3h...@gmail.com) wrote: Hi Guys, Do I understand

[akka-user] Stopping of PersistentActor

2017-09-26 Thread Yaroslav Klymko
Hi Guys, Do I understand correctly that there is high chance to have events persisted without handlers performed if persistent actor stopped? ref ! cmd journal ! WriteMessages ref ! PoisonPill deadLetters <- WriteMessagesSuccess Is it intendant? Are there any plans to fix or improve this