Clustered and locally persisted cache?

classic Classic list List threaded Threaded
2 messages Options
Henrik Lundahl Henrik Lundahl
Reply | Threaded
Open this post in threaded view
|

Clustered and locally persisted cache?

Hi

I would like to set up a cache in a two node cluster where

* node A
    * loads the cache from local files at startup if they exist, otherwise it
    * loads data into the cache from an external source and then
    * saves the whole cache down to local files.
* node B
    * loads the cache from local files at startup if they exist, otherwise it
    * gets data into the cache through the cluster if there is a viable network connection and then
    * saves the whole cache down to local files

I would at the same time like to have only part of the cache in memory, i.e. it should swap to disk. Is there a reasonably simple way to accomplish all this?


--
Henrik

vkulichenko vkulichenko
Reply | Threaded
Open this post in threaded view
|

Re: Clustered and locally persisted cache?

Hi Henrik,

I'm not sure I completely understood your use case, but it sound like you should take a look at persistence capabilities of Ignite [1]. Cache store allows to load the data from external storage and write it back when data is updated.

Let us know if it works for you or if you have more questions.

[1] https://apacheignite.readme.io/docs/persistent-store

-Val