Search code examples
ignitedistributed-caching

How do I support schema change in Ignite as well as addition of new Cache?


I want to dynamically create cache for new mysql table in Ignite. I don't have table's class definition at runtime. I regularly get new data in HDFS for those tables in avro format. I want to ingest that incremental data into Ignite Cache by creating cache at runtime if it doesn't exist for that table and then put data into cache. Also I want to query on that data. Plus what happens if schema changes in MySql ? Will BinaryCache in Ignite help in solving my use case ?


Solution

  • You can create/drop caches (hence tables) in runtime. If we don't have classes in runtime then you can configure via QueryEntitry. Refere the following page https://apacheignite.readme.io/docs/indexes section QueryEntity Based Configuration. In the next 2.3 release (which community plan to release in nearest future) Apache Ignite will support alter table add column command. You can track status this features by the following links:

    https://issues.apache.org/jira/browse/IGNITE-5572

    https://issues.apache.org/jira/browse/IGNITE-6283