Re: [akka-user] akka 2.4.2 [java] stopping http-server and flow handling IncomingConnection

2016-04-03 Thread paweł kamiński
Switch.shutdown or abort > 3. shut down ActorSystem > > -Endre > > On Fri, Apr 1, 2016 at 11:33 AM, Viktor Klang > wrote: > >> Call 'shutdown' on the ActorSystem? Or only the Materializer? >> >> On Fri, Apr 1, 2016 at 11:29 AM, paweł kamiński > &

Re: [akka-user] ANNOUNCE: Akka 2.4.3 released!

2016-04-03 Thread paweł kamiński
+1 On Friday, 1 April 2016 18:38:32 UTC+2, drewhk wrote: > > Yay! > > On Fri, Apr 1, 2016 at 6:37 PM, Konrad Malawski > wrote: > >> ANNOUNCE: Akka 2.4.3 Released >> >> Dear hakkers, >> >> we—the Akka committers—are proud to announce the third patch release of >> Akka 2.4. >> >> This release focu

Re: [akka-user] akka 2.4.2 [java] stopping http-server and flow handling IncomingConnection

2016-04-01 Thread paweł kamiński
ination" or something with a > code path attached to it? > > On Thu, Mar 31, 2016 at 11:53 PM, paweł kamiński > wrote: > >> dont take it personally, there is a lot to process and sometimes it is >> easy to overlook the most important part, I guess I didn't

Re: [akka-user] akka 2.4.2 [java] stopping http-server and flow handling IncomingConnection

2016-03-31 Thread paweł kamiński
GraphStage (read up on custom stream > processing – cancel() and friends). > > -- > Cheers, > Konrad 'ktoso’ Malawski > <http://akka.io>Akka <http://akka.io> @ Lightbend <http://typesafe.com> > <http://lightbend.com> > > On 31 March 2016 at 23

Re: [akka-user] akka 2.4.2 [java] stopping http-server and flow handling IncomingConnection

2016-03-31 Thread paweł kamiński
Wednesday, 30 March 2016 10:39:35 UTC+2, paweł kamiński wrote: > > I thought bold is new black, coming back with a bang... > > ok, your explanation makes kind of sense ;] all I expected was a shutdown > method with timeout. > and yeah a section with examples would be nice and I

Re: [akka-user] akka 2.4.2 [java] stopping http-server and flow handling IncomingConnection

2016-03-30 Thread paweł kamiński
I thought bold is new black, coming back with a bang... ok, your explanation makes kind of sense ;] all I expected was a shutdown method with timeout. and yeah a section with examples would be nice and I can write one once I understand how it works ;] I understand that I need to hold each conn

[akka-user] akka 2.4.2 [java] stopping http-server and flow handling IncomingConnection

2016-03-29 Thread paweł kamiński
hi, I have a simple http service that binds to a given port and starts accepting IncomingConnection. the server is created by actor on its preStart callback and stopped on postStop. everything works fine until I try to kill the actor and force http-server to stop. public void start() { Ac

Re: [akka-user] akka 2.4.2 java - How to create custom ContentType

2016-03-09 Thread paweł kamiński
ook into it soon! > > -- > Cheers, > Konrad 'ktoso’ Malawski > <http://akka.io>Akka <http://akka.io> @ Lightbend > <http://www.google.com/url?q=http%3A%2F%2Ftypesafe.com&sa=D&sntz=1&usg=AFQjCNFC6SplTJxAP7AExZl1lClfJ-tq6w> > <http://light

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-09 Thread paweł kamiński
:02 UTC+1, paweł kamiński wrote: > > thanks, for all help. > > it is running for ever as I am testing concepts of updating a remote > client asynchronously, in real time Updater will get updates from other > actors and yes I will add supervision strategies. > Im running thi

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-08 Thread paweł kamiński
flow. On Tuesday, 8 March 2016 23:33:38 UTC+1, Rafał Krzewski wrote: > > W dniu wtorek, 8 marca 2016 23:10:38 UTC+1 użytkownik paweł kamiński > napisał: >> >> but this is impossible to change concurrently as I log it and then pass >> to Pattern#ask. I just wonder wh

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-08 Thread paweł kamiński
s modified concurrently by > different threads, but since updater is a local variable in the closure > passed to mapAsync, this really shouldn't been happening... Weird. > > I guess that's all I can say without digging in with a debugger :) Good > luck! > Rafał > > W

Re: [akka-user] akka 2.4.2 java - How to create custom ContentType

2016-03-08 Thread paweł kamiński
typesafe.com> > <http://lightbend.com> > > On 8 March 2016 at 17:48:44, paweł kamiński (kam...@gmail.com > ) wrote: > > OK, thanks, any hints how to work this around? > > I ll create an issue. > > On Tuesday, 8 March 2016 17:37:48 UTC+1, Konrad Malawski w

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-08 Thread paweł kamiński
user/B1#385306581] was not delivered. [3] dead letters encountered. I wonder why I get message from *deadLetters *and why it is sent to* B1 *actor. the result is that computed messages for B12 will be never sent back. also requested timeouts messages are not delivered :/ I ve messed this up :) O

Re: [akka-user] akka 2.4.2 java - How to create custom ContentType

2016-03-08 Thread paweł kamiński
ly something we'll do next up, > please keep the feedback coming, thanks! > > > > -- > Cheers, > Konrad 'ktoso’ Malawski > <http://akka.io>Akka <http://akka.io> @ Lightbend <http://typesafe.com> > <http://lightbend.com> > > On 8 Marc

[akka-user] akka 2.4.2 java - How to create custom ContentType

2016-03-08 Thread paweł kamiński
I try to force my http server (using only http-core) to respond with headers. I get from request Accept header String mime = request.getHeader(Accept.class) .map(HttpHeader::value) .orElse("application/json"); but then it is not clear to me how to create custom Content-Type he

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-08 Thread paweł kamiński
like Source.actorPublisher() / Sink. actorRef(). this way we could pass Props of publisher which would transform incoming messages into something else. On Monday, 7 March 2016 11:28:03 UTC+1, paweł kamiński wrote: > > yep, i'm now thinking about duplex flow so I can push incoming

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-07 Thread paweł kamiński
2016 10:43:26 UTC+1, Rafał Krzewski wrote: > > W dniu poniedziałek, 7 marca 2016 10:08:23 UTC+1 użytkownik paweł kamiński > napisał: > >> thanks for response. >> >> well ask pattern is a way to go but I thought I could avoid it and use >> only flow's con

[akka-user] Re: [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-07 Thread paweł kamiński
java.lang.Object-akka.util.Timeout- > > > W dniu niedziela, 6 marca 2016 23:25:07 UTC+1 użytkownik paweł kamiński > napisał: >> >> hi, >> I have a simple HTTP service that accepts connections and keeps them >> alive. >> Once client sends something I loo

[akka-user] [akka java 2.4.2] creating a flow sending elements of the stream to given actorRef and pushing results back to stream

2016-03-06 Thread paweł kamiński
hi, I have a simple HTTP service that accepts connections and keeps them alive. Once client sends something I look-up actorRef (WORKER) based on path/query of request and I would like to wait for response from such actor so I can respond back to client. this is server to server communication s

Re: [akka-user] Re: Akka streams 1.0 with java sdl - exposing BidiFlow as Flow

2015-09-18 Thread paweł kamiński
thanks for detailed answer, and yes now I understand it, it just was't explained in details in docs and I got impression it should be doable and useful :) On Friday, 18 September 2015 13:07:40 UTC+2, drewhk wrote: > > Hi Pawel, > > On Fri, Sep 18, 2015 at 12:19 PM, paweł

Re: [akka-user] Re: Akka streams 1.0 with java sdl - exposing BidiFlow as Flow

2015-09-18 Thread paweł kamiński
m one end to get Flow of the other end >> >> On Wednesday, 16 September 2015 23:09:46 UTC+2, paweł kamiński wrote: >>> >>> hi, >>> >>> I folowed >>> http://doc.akka.io/docs/akka-stream-and-http-experimental/1.0/java/stream-graphs.html#Bidirecti

[akka-user] Re: Akka streams 1.0 with java sdl - exposing BidiFlow as Flow

2015-09-18 Thread paweł kamiński
I guess the answer can be found on the same page I referred. 1. final Flow flow = stack.atop(stack. reversed()).join(pingpong); I need to close BidiFlow from one end to get Flow of the other end On Wednesday, 16 September 2015 23:09:46 UTC+2, paweł kamiński wrote: > > hi, > &g

[akka-user] Akka streams 1.0 with java sdl - exposing BidiFlow as Flow

2015-09-16 Thread paweł kamiński
hi, I folowed http://doc.akka.io/docs/akka-stream-and-http-experimental/1.0/java/stream-graphs.html#Bidirectional_Flows and its section describing BidiFlow but my brain has just fried when I tried to figure out how to expose left side of such BidiFlow as Flow. in other words how to hide the

Re: [akka-user] Akka Streams handling tcp request with dynamic response

2015-09-08 Thread paweł kamiński
ts.map { in => sourceFor(in) }.flatten(FlattenStrategy.concat) > > I have written some TCP examples for an older ML thread, they might help > to give you some inspiration: > https://gist.github.com/drewhk/25bf7472db04b5699b80 > > (try to run them to see what they do) >

[akka-user] Akka Streams handling tcp request with dynamic response

2015-09-06 Thread paweł kamiński
hi, I have a problem with defining a flow that reacts to incoming data and producing dynamic response. lets say I have a tcp server Tcp .get(system) .bind(host, port) .to(foreach(con -> { con.handleWith(handlerFlow, materializer); })) .run(mate

Re: [akka-user] Re: akka streams 1.0 and http routing - in java

2015-08-26 Thread paweł kamiński
low > you should be able to use `.mapMaterializedValue(m -> m)` to > convert the type. > > Johannes > > > On Tue, Aug 25, 2015 at 11:19 PM, paweł kamiński > wrote: > > OK I give up again :) > > > > so if I have > > > > Source source

[akka-user] Re: akka streams 1.0 and http routing - in java

2015-08-25 Thread paweł kamiński
ies.create(contentType, length, data) > > to create a (non-chunked) streamed default entity. > > HTH > Johannes > > > > On Monday, August 10, 2015 at 10:38:40 PM UTC+2, paweł kamiński wrote: > hi, > probably again I ve overlooked it in documentati

[akka-user] Re: akka streams 1.0 and http routing - in java

2015-08-11 Thread paweł kamiński
the Source provides), you can also use > > HttpEntityies.create(contentType, length, data) > > to create a (non-chunked) streamed default entity. > > HTH > Johannes > > > > On Monday, August 10, 2015 at 10:38:40 PM UTC+2, paweł kamiński wrote: > hi, > probably again

[akka-user] akka streams 1.0 and http routing - in java

2015-08-10 Thread paweł kamiński
hi, probably again I ve overlooked it in documentation but I cannot find a way to respond to a http request with streamed response. probably HttpEntityChunked should be used but again I cannot figure out how to set entities and flows correctly. this is basic example private RouteResult getEven

Re: [akka-user] akka streams 1.0 - actor publisher do not receive demand

2015-08-07 Thread paweł kamiński
p the buffer. > If you would use a iterator based Source to emit the 100 elements instead > of sending them via the ActorPublisher actor you would have backpressure > all the way. > > What is it that you are trying to build? > > On Thu, Aug 6, 2015 at 9:42 PM, paweł kamiński >

Re: [akka-user] akka streams 1.0 - actor publisher do not receive demand

2015-08-06 Thread paweł kamiński
: > > > > On Sun, Aug 2, 2015 at 1:42 PM, paweł kamiński > wrote: > >> hi, >> I have simple actor producer based on >> http://doc.akka.io/docs/akka-stream-and-http-experimental/1.0/java/stream-integrations.html#ActorPublisher >> >> public clas

[akka-user] akka streams 1.0 - actor publisher do not receive demand

2015-08-02 Thread paweł kamiński
hi, I have simple actor producer based on http://doc.akka.io/docs/akka-stream-and-http-experimental/1.0/java/stream-integrations.html#ActorPublisher public class MessageProducer extends AbstractActorPublisher { private final static Logger logger = LoggerFactory.getLogger(MessageProducer.cla