Re: [akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-18 Thread Giovanni Alberto Caporaletti
Hi, https://gist.github.com/TrustNoOne/c7087713fa78375b2cb0 is a small POC I did today to check if the PersistentViewSource idea worked. I added some docs since I decided to post it but it has not been tested (well, I actually ran it like 10 times total lol). I'm not sure but there was somethi

Re: [akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-17 Thread Konrad Malawski
API wise it could help you migrate once query side is out I guess. The type of the stream is simply Source[Any, _] (can be done with T), so if the rest of your app depends on such then you could do it. Getting backpressure will require some gymnastics but should be doable (don't poll if no deman

Re: [akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-17 Thread Giovanni Alberto Caporaletti
Hi Konrad do you think that creating a "streams adapter" that exposes the current PersistentView as a stream and then switching to the new impl when it's stable would be a good idea? On Friday, 17 July 2015 10:52:28 UTC+2, Konrad Malawski wrote: > > Hi guys, > A few things to add to the discussi

Re: [akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-17 Thread Konrad Malawski
Hi guys, A few things to add to the discussion here :-) Multiple journals are supported in Akka Persistence since 2.4-M1. https://github.com/akka/akka/issues/15587 In general 2.4 will include all the things that were missing in persistence in its experimental phase. > *Push model:*Akka Persisten

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-16 Thread haghard
-That looks like a convenient syntax that does the same thing as a persistent view does, tailored for users of scalaz streams, or am I missing something? Yes -Can you take multiple eventlogs and combine them into one reproducible ordered stream. So that if you make decisions (validate precondi

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-15 Thread Giovanni Alberto Caporaletti
ok thanks.. I guess in this simple case I don't need a persistent view, I could directly save (asynchronously) the events on the read store so that I don't have to wait the 5 secs. Persistent views are not much use if I don't keep a modified (aggregated or not) in-memory view of my data, or at

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-15 Thread Magnus Andersson
Hi Giovanni: Yes, I suppose you could write directly to a read store in this case. As I wrote in my case I wanted the projection in memory as well to validate conditions before creating output (like allowing the user to download a file). Amiri: Yes that is correct. The difference between 1 and

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-15 Thread Amiri Barksdale
On Wednesday, July 15, 2015 at 10:43:55 AM UTC-7, Giovanni Alberto Caporaletti wrote: > > Hi Magnus. > a question concerning your pull model: if the updates are idempotent, why > would I need a parent aggregate? Can't the views directly populate the read > store? > This is a great question,

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-15 Thread Giovanni Alberto Caporaletti
Hi Magnus. a question concerning your pull model: if the updates are idempotent, why would I need a parent aggregate? Can't the views directly populate the read store? Cheers G On Tuesday, 14 July 2015 12:45:20 UTC+2, Magnus Andersson wrote: > > Hi > > I looked into this question in the past.

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-15 Thread Magnus Andersson
Hi Hagard: That looks like a convenient syntax that does the same thing as a persistent view does, tailored for users of scalaz streams, or am I missing something? Can you take multiple eventlogs and combine them into one reproducible ordered stream. So that if you make decisions (validate pr

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-14 Thread haghard
Hi, Please take a look at https://github.com/krasserm/streamz You can read concrete journal with ```replay("processorA")``` and write in anywhere manually without interaction with PersistentView Hope it helps вторник, 14 июля 2015 г., 10:20:29 UTC+3 пользователь Amiri Barksdale написал: > > I

[akka-user] Re: Newbie Questions About PersistentView and Populating Read Datastores

2015-07-14 Thread Magnus Andersson
Hi I looked into this question in the past. There are some long threads in the mailing lists and aggregated views seems to be something that will be considered for Akka in the future (unless I misunderstood the threads) but it is only after akka-http and akka-streams are matured. As for doing