Skip to content

Instantly share code, notes, and snippets.

@mmarkus
Created October 6, 2011 12:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mmarkus/1267303 to your computer and use it in GitHub Desktop.
Save mmarkus/1267303 to your computer and use it in GitHub Desktop.
public void testMultipleTxSameKey() throws Exception {
final Cache<String, Object> cache1 = cache(0, "atomic");
final FineGrainedAtomicMap<String, String> map1 = AtomicMapLookup.getFineGrainedAtomicMap(cache1, "testMultipleTx",true);
tm(0, "atomic").begin();
map1.put("k1", "v");
tm(0, "atomic").rollback();
final FineGrainedAtomicMap<Object, Object> instance = AtomicMapLookup.getFineGrainedAtomicMap(cache1, "testMultipleTx", true);
assert !instance.containsKey("k1");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment