Transaction tx = mgr.getTransaction();
// inject InvocationContext
setupTransactions(cache, tx);
SamplePojo pojo = new SamplePojo(21, "test");
cache.put("/one/two", "key1", pojo);
assertEquals(pojo, cache.get("/one/two", "key1"));
//suspend current transaction
mgr.suspend();
//start a new transaction
mgr.begin();
Transaction tx2 = mgr.getTransaction();
// inject InvocationContext
setupTransactions(cache, tx2);
SamplePojo pojo2 = new SamplePojo(22, "test2");
cache.put("/one/two", "key2", pojo2);
assertEquals(null, cache.get("/one/two", "key1"));
assertEquals(pojo2, cache.get("/one/two", "key2"));