Skip to content

Instantly share code, notes, and snippets.

@vinaykumar2
vinaykumar2 / MainClass.java
Last active September 5, 2017 20:25
persistent storage in ehcahce - cacheManagerPeerProviderFactory –It is used for saying “Hello, I’m here!” and allows to discover the other CacheManager in the cluster and be discovered by other nodes. It accepts only two arguments (class and properties). cacheEventListenerFactory — It is used for receiving notification about cache update by othe…
package com.techartifact.caching;
import java.util.ArrayList;
import java.util.List;
import net.sf.ehcache.Cache;
import net.sf.ehcache.CacheManager;
import net.sf.ehcache.Element;
// this is main class.