Apache Ignite™ is a rapidly changing platform: if you were to look at 3 years ago, you would see a completely different product. In this talk, we will follow the path that led Apache Ignite™ from a compute grid and data grid product to a distributed database and In-memory computing platform. We will examine technical tasks and decisions that were driving the transformations (as an example - how we added native persistence to Apache Ignite™) and will wrap up the talk with the outstanding problems that are going to be solved for Apache Ignite™.
Alternate title: How and why Apache Ignite™ is Changing from an In-Memory Data Grid into an In-Memory Database.
In this talk, we will follow the path that led Apache Ignite™ from a compute grid and data grid product to a distributed database and an in-memory computing platform. We will examine technical tasks and decisions that were driving the transformations.
Step back: who knows about Ignite?
Traditional databases don’t scale. Buy bigger and bigger boxes until you run out of money.
Traditional compute grids have to copy data across the network, which at modern scale is just impractical.
Ignite scales horizontally and sends compute to the data rather than the other way around.
In memory for speed. Disk persistence for volume.
Memory data grid
Optionally backed by the “Cache Store”
SQL works as fork-join – SQL executed on every node, results joined together
Resuts correct results in limited use cases
SQL only in-memory
Restart means loading all data
Centralised store – scalablity issues
LocalStore designed to allow faster restarts
Local Store is an append-only structure with periodical compactions
Still need to load data from local store to memory (on datasets of 100s of GBs warmup could take 3+ hours)
Keys are still residing in memory, so the data set size is limited
SQL functionality is improved (two-step queries like plain ORDER BY, GROUP BY, some cases of distributed joins are implemented, but still there are restrictions, not all queries return correct results, a user must check collocation rules)
So better but still missing stuff. What are our requirements for The Best system?
Algorithms for Recovery and Isolation Exploiting Semantics
Ignite 1.x had options for on- and off-heap storage. 2.x only off-heap
Unlike LocalStore (and competition), it uses a WAL… like legacy databases. Crash recovery
ABA problem -- thread synchronization (https://en.wikipedia.org/wiki/ABA_problem)
We’ve mostly talked about the Good Stuff.. But there are complications
What’s happening here?
Baseline topology
… and the discussion about Java 10 brings us to … the futur
Improve SQL
What’s wrong with H2? H2 is not a distributed database with a very simple planner. Ignite uses H2 internal APIs and hacks to integrate with H2.
No query execution graph. A query is effectively executed based on AST with minimum transformations
H2 planner does not know about distributed SQL, it is almost impossible to execute complex SQL queries (subqueries, complex aggregations, non-colocated tables) effectively
No memory control
Currently investigating using Apache Calcite as a query optimizer + custom execution engine. See Apache Developers list (+IEP)
Improve Split-Brain handling out-of-the-box
Require users to implement TopologyValidator
Should work without users writing a single line of code
Modularisation
don’t download everything
Dependencies for stuff like Spark / Kafka with different release schedules
Even “internal” stuff like ML