Re: [akka-user] Akka typed - first impressions

2018-02-13 Thread 'Michal Borowiecki' via Akka User List
Hi Patrik, Thanks for the latest snapshot. I've been trying to play around with akka typed by migrating the project I'm working on and previously I'd been stuck at implementing stashing. Now with the StashBuffer it got simple. Overall I'm really happy. It took a lot of time but I managed to

[akka-user] Re: Kafka flow shutting down unexpectedly when brokers fail

2018-01-25 Thread 'Michal Borowiecki' via Akka User List
I use RestartSource.withBackoff to recover from broker outages. https://doc.akka.io/docs/akka/current/stream/stream-error.html#delayed-restarts-with-a-backoff-stage Hope that helps. MichaƂ On Friday, 12 January 2018 22:41:04 UTC, Sean Rohead wrote: > > I am using akka-stream-kafka 0.18. I have

Re: [akka-user] Akka Kafka Stream - only once delivery

2017-06-28 Thread 'Michal Borowiecki' via Akka User List
If you need exactly once semantics against your target database, the common pattern is to store your last processed offset in that database transactionally together with your output records, instead of committing back to kafka. On startup you'd read the last offset from your database and seek

Re: [akka-user] Stream deduping

2017-06-24 Thread 'Michal Borowiecki' via Akka User List
I drafted an implementation outline in kafka-streams to address the problem of sliding-window reordering (to cater for late messages within the time window), it also caters for de-duplication:

Re: [akka-user] State Replication in ORMultiMap

2017-06-18 Thread 'Michal Borowiecki' via Akka User List
ORMap and ORMultiMap don't mention delta support. On the contrary, docs for Maps say: When a data entry is changed the full state of that entry is replicated to other nodes, i.e. when you update a map the whole map is replicated. Therefore, instead of using one|ORMap|with 1000 elements it is

Re: [akka-user] Downing Provider - Missing Unreachable messages

2017-05-27 Thread 'Michal Borowiecki' via Akka User List
Hi Patrik, I think indeed that is what we're seeing. It happened in production and we can easily reproduce it by bringing down network connections one at a time. However, I wonder if this is something that could be solved in akka itself, as opposed to trying to implement a custom downing

Re: [akka-user] Using Akka for Data Synchronization Use Case

2017-05-13 Thread 'Michal Borowiecki' via Akka User List
Hi Santanu, I'm not sure I know enough about your requirements to advise. In microservices for each piece of data I'd have only one of the services be the "source of truth" for that data and others subscribe to events from that microservice. In your original case, however, it's not clear if

Re: [akka-user] Restart stream with backoff

2017-05-09 Thread 'Michal Borowiecki' via Akka User List
Sounds like what could help in your organization is using a higher-level abstraction, such as Lagom. You don't need to be comfortable with actors to use it and it does provide a wrapper around reactive-kafka (or akka-stream-kafka as it's currently known) with exponential backoff restarts:

Re: [akka-user] Using Akka for Data Synchronization Use Case

2017-05-08 Thread 'Michal Borowiecki' via Akka User List
Hi Santanu, If data consistency is key, please start by thinking carefully about what you mean by consistency. How strong your consistency guarantees actually need to be? I see no reason not to build your system using akka, but be aware that message-driven distributed systems will generally

Re: [akka-user] SSH Tunneling and Akka remote

2017-05-06 Thread 'Michal Borowiecki' via Akka User List
I've not tried that, but it reminded me of something in the docs that says: *Important*: Using setups involving Network Address Translation, Load Balancers or Docker containers violates assumption 1, unless additional steps are taken in the network configuration to allow symmetric

Re: [akka-user] Akka Flow map from X to X, the materialize

2017-05-03 Thread 'Michal Borowiecki' via Akka User List
Hi Igmar, You can do a map on the source and pass the new returned Source as the second parameter to Flow.fromSinkAndSource instead of the original source. Something like this (untested): final Source source = Source.range(1, 100).map(v -> new X()); final Sink

Re: [akka-user] Akka and RDMA

2017-05-02 Thread 'Michal Borowiecki' via Akka User List
Hi Marc, Sounds very interesting but I couldn't find evidence of Aeron directly supporting RDMA in the links your provided or otherwise. Can you please point me to your sources? I found this github ticket https://github.com/real-logic/Aeron/issues/220 but it's still open. Thanks, Michal

Re: [akka-user] Re: akka kafka stream parallel processing

2017-05-01 Thread 'Michal Borowiecki' via Akka User List
I think you got your imports wrong. Given the call to .asJava(), I'm guessing you've imported Consumer from the scaladsl. If you use javadsl you'll get akka.stream.javadsl.Source, not akka.stream.scaladsl.Source in the Tuple2. committablePartitionedSource() is giving you a Source of tuples,

Re: [akka-user] Re: Akka HTTP - Can't return completeWithFuture

2017-04-29 Thread 'Michal Borowiecki' via Akka User List
Hi Thibault, Looks like the docs are out of date. If you read the compilation error message carefully, you'll notice Jackson.marshaller is giving you a |Marshaller| while completeWithFuture is expecting a

Re: [akka-user] Chunked response with akka-http 10.x

2017-04-20 Thread 'Michal Borowiecki' via Akka User List
Hi Thibault, I do this kind of thing with Source.fromIterator(...) passing it an iterator obtained from a java stream. In your case, it would look something like: Source source = Source.fromIterator( () -> Stream.generate( ()-> UUID.randomUUID() ).iterator()

Re: [akka-user] Re: Has akka-http has abandoned per request actors in favor an anti-pattern DSL?

2017-04-19 Thread 'Michal Borowiecki' via Akka User List
Hi there, Just to chip in for balance. We're using akka http and the DSL in a real world business app. The fact we don't have hundreds of routes or don't have to call 10s of actors per request doesn't make our app any less a "real world business app". Just that ours is small. And we're

Re: [akka-user] using AKKA-HTTP and AKKA-Camel together on the same port possible?

2017-04-13 Thread 'Michal Borowiecki' via Akka User List
Both http servers (jetty and akka-http) will try to bind to the specified port (9001) and the OS will only allow the first one to succeed, leading to the exception you are seeing in the process that is second to start. If you must have them serve requests on the same port, then the way I see

Re: [akka-user] Anyway to speed up Compression.gunzip?

2017-04-06 Thread 'Michal Borowiecki' via Akka User List
While there is little I can say about the speed of decompressing an individual file, you can design your pipeline so that multiple files are decompressed in parallel, but you probably thought of that already ;) Thanks, Michal On 06/04/17 03:37, Sean Callahan wrote: I doubt there is really

Re: [akka-user] Re: Understanding 'Leader can currently not perform its duties' message

2017-04-04 Thread 'Michal Borowiecki' via Akka User List
Indeed. This is the relevant bit of docs I believe (http://doc.akka.io/docs/akka/2.4.17/common/cluster.html#Membership): The node identifier internally also contains a UID that uniquely identifies this actor system instance at thathostname:port. Akka uses the UID to be able to reliably

Re: [akka-user] Seed node shutdown/restart and Cluster rejoin

2017-04-04 Thread 'Michal Borowiecki' via Akka User List
Hi Unmesh, If you configure multiple seed nodes, then only at least one of the has to be up for new (or restarted) members to join. In our deployment we have a pretty static membership (we don't add nodes dynamically), so we set all nodes to be seed nodes, no harm in that. Hope that helps,

Re: [akka-user] Re: Understanding 'Leader can currently not perform its duties' message

2017-04-04 Thread 'Michal Borowiecki' via Akka User List
Hi Unmesh, AFAIK, the crashed node has to be downed (whether manually or automatically) for the cluster to reach convergence. Only once there are no unreachable nodes observed by any member can the leader resume it's duties and allow the new member (your re-started instance) to join. For

[akka-user] akka-streams-kafka exponential backoff

2017-03-28 Thread 'Michal Borowiecki' via Akka User List
Hello, Lagom has a nice feature when subscribing to kafka topics that upon failure it re-creates the flow with exponential backoff. I see this is implemented by wrapping the KafkaSubscriberActor props with BackoffSupervisor props:

Re: [akka-user] Re: How to listen to events on CassandraJournalProvider ?

2017-03-21 Thread 'Michal Borowiecki' via Akka User List
Cassandra driver? Thanks, kant On Mon, Mar 13, 2017 at 1:57 AM, 'Michal Borowiecki' via Akka User List <akka-user@googlegroups.com <mailto:akka-user@googlegroups.com>> wrote: Also, there's a setting called "cassandra-journal.pubsub-minimum-interval", which i

Re: [akka-user] Re: Naive question

2017-03-20 Thread 'Michal Borowiecki' via Akka User List
Hi Ryan, Kafka's log compaction is not an accurate analogy, as it simply works by preserving the last msg with a given key, removing previous messages with that key. That's not the same as the concept of snapshots in event sourcing. Cheers, Michal On 15/03/17 16:29, 'Ryan Tanner' via

Re: [akka-user] Re: How to listen to events on CassandraJournalProvider ?

2017-03-13 Thread 'Michal Borowiecki' via Akka User List
Also, there's a setting called "cassandra-journal.pubsub-minimum-interval", which if set will cause the journal to notify the persistence query side of new writes, so it can only poll when needed instead of doing so periodically. Cheers, Michal On 12/03/17 19:15, Patrik Nordwall wrote: Tal

[akka-user] Re: How to integrate customized endpoint in akka

2017-01-10 Thread 'Michal Borowiecki' via Akka User List
Hi Dai, Have you had a look at http://doc.akka.io/docs/akka/current/java/camel.html yet? Cheers, Michal -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >> http://doc.akka.io/docs/akka/current/additional/faq.html >> Search the archives: