Infinispan file store with pre-loaded data

2019-09-13 11:55发布

I am using infinispan as cache provider. I have a flat file containing key (long) value (string) pairs. Upon application load time, i want an embedded infinispan cache to start with flat file as the storage so that the contents of the flat file is the system of record and the contents of the file is cached by infinispan. As new records get added to cache, i want the flat file to be appended. Is it possible with infinispan?

1条回答
一夜七次
2楼-- · 2019-09-13 12:22

Principially yes, you have to implement you own cache loader/store that will read and modify that file. Checkout SingleFileStore for a simple implementation of the SPI (SingleFileStore is general-purpose file-based store).

查看更多
登录 后发表回答