Forgive me if I missed stuff, please point me in the right direction if you've covered it, but some questions if I may (after I've said well done!). I've considered this problem before and it seems very difficult . So: 1. Do you have a paper on this with a rigorous justification of the algorithm? 2. This surely has to rely on the isolation level being pretty high, or EventReduce might be reading while n other process…
1. No I do not have a paper. I thought a lot about publishing a paper first but then decided against it, because I think that good code and tests and demos are more valuable. 2. EventReduce is mostly useful for realtime applications. I myself use it in a NoSQL database (RxDB). There you stream data and events and a single document write is the most atomic 'transaction' you can do. If you need transactional serial wri…
EventReduce: An algorithm to optimize database queries that run multiple times
11–20 of 87 posts
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#12Earlier quoted context omitted.
1. No I do not have a paper. I thought a lot about publishing a paper first but then decided against it, because I think that good code and tests and demos are more valuable. 2. EventReduce is mostly useful for realtime applications. I myself use it in a NoSQL database (RxDB). There you stream data and events and a single document write is the most atomic 'transaction' you can do. If you need transactional serial wri…
BDDs you are using, are they zero-supressed decision diagrams or it was not necessary to do these kinds of optimizations?
The was no good JavaScript implementation for BDDs so I had to create my own one https://github.com/pubkey/binary-decision-diagram
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#13This sounds like (a simpler version of?) Lambda Architecture [1, 2] [1] https://en.wikipedia.org/wiki/Lambda_architecture [2] https://www.manning.com/books/big-data
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#14Forgive me if I missed stuff, please point me in the right direction if you've covered it, but some questions if I may (after I've said well done!). I've considered this problem before and it seems very difficult . So: 1. Do you have a paper on this with a rigorous justification of the algorithm? 2. This surely has to rely on the isolation level being pretty high, or EventReduce might be reading while n other process…
1. No I do not have a paper. I thought a lot about publishing a paper first but then decided against it, because I think that good code and tests and demos are more valuable. 2. EventReduce is mostly useful for realtime applications. I myself use it in a NoSQL database (RxDB). There you stream data and events and a single document write is the most atomic 'transaction' you can do. If you need transactional serial wri…
Edit: your example gives replaceExisting() so that's supporting an update of some kind.
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#15Earlier quoted context omitted.
1. No I do not have a paper. I thought a lot about publishing a paper first but then decided against it, because I think that good code and tests and demos are more valuable. 2. EventReduce is mostly useful for realtime applications. I myself use it in a NoSQL database (RxDB). There you stream data and events and a single document write is the most atomic 'transaction' you can do. If you need transactional serial wri…
So if I get you, it's for append-only data - probably no updates, definitely no no deletions? Still don't get how you don't need logical clocks to pick out the delta(s), but thanks for your prompt answer. Edit: your example gives replaceExisting() so that's supporting an update of some kind.
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#16Materialize exists to efficiently solve the view maintenance problem: https://materialize.io/
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#17Earlier quoted context omitted.
So if I get you, it's for append-only data - probably no updates, definitely no no deletions? Still don't get how you don't need logical clocks to pick out the delta(s), but thanks for your prompt answer. Edit: your example gives replaceExisting() so that's supporting an update of some kind.
No it is explicitly not for append-only data. It works with inserts, updates and deletes. I think I have problems understanding what exactly you mean by the need for a logical clock. The algorithm is feeded with the old query results plus one event, and then returns the new query results. Since there is only one event at each point of time, it does not have to order or maintain them.
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#18Re: EventReduce: An algorithm to optimize database queries that run multiple times
#19Earlier quoted context omitted.
So if I get you, it's for append-only data - probably no updates, definitely no no deletions? Still don't get how you don't need logical clocks to pick out the delta(s), but thanks for your prompt answer. Edit: your example gives replaceExisting() so that's supporting an update of some kind.
No it is explicitly not for append-only data. It works with inserts, updates and deletes. I think I have problems understanding what exactly you mean by the need for a logical clock. The algorithm is feeded with the old query results plus one event, and then returns the new query results. Since there is only one event at each point of time, it does not have to order or maintain them.
Re: EventReduce: An algorithm to optimize database queries that run multiple times
#20Earlier quoted context omitted.
No it is explicitly not for append-only data. It works with inserts, updates and deletes. I think I have problems understanding what exactly you mean by the need for a logical clock. The algorithm is feeded with the old query results plus one event, and then returns the new query results. Since there is only one event at each point of time, it does not have to order or maintain them.
I had the same question as #2. Basically, it has to be the front-end to any event that reads/writes the data, in strict order of occurrence?
But easier you do that by using a database that already provides a changestream like couchdb, Postgres, mongodb and so on.