I'm using Infinispan 5.0.1 for my caching needs.
The problem I'm having is that I need to get data back from the cache in the same order it was put in the cache. For example:
Cache<String, String> myCache = defaultCacheManager.getCache("myCache");
myCache.put("1", "ONE");
myCache.put("2", "TWO");
myCache.put("3", "THREE");
myCache.keySet();
Set<String> keySet = myCache.keySet();
for (String key : keySet) {
System.out.println(myCache.get(key));
}
This should print out: ONE TWO THREE