October 20th, Q&A session: Get you issues solved and questions answered!

GitHub logo

Apache Ignite as MyBatis L2 Cache

Apache Ignite can be used as a MyBatis L2 cache that distributes and caches data across a cluster of machines.

If you are an Apache Maven user, simply add the following dependency to the pom.xml:


Alternatively, you can also download the zip bundle, decompress it and add the jars in the classpath.

Then, just specify it in the mapper XML as follows:

<mapper namespace="org.acme.FooMapper">
  <cache type="org.mybatis.caches.ignite.IgniteCacheAdapter" />

and configure your Ignite cache in config/default-config.xml. (Simple reference configurations are available on Github)