[infinispan-issues] [JBoss JIRA] Created: (ISPN-1210) TreeCache getData method returns null Map

Annadurai Narayanan (JIRA) jira-events at lists.jboss.org
Tue Jun 28 14:45:23 EDT 2011


TreeCache getData method returns null Map
-----------------------------------------

                 Key: ISPN-1210
                 URL: https://issues.jboss.org/browse/ISPN-1210
             Project: Infinispan
          Issue Type: Bug
          Components: Tree API
    Affects Versions: 5.0.0.CR6
         Environment: Windows OS
            Reporter: Annadurai Narayanan
            Assignee: Manik Surtani
            Priority: Blocker


TreeCache getData() method returns null instead of mapped value from the node. Please see the unit test case written in junit.

public class TreeCacheTest extends Assert {
	
	
	@Test
	public void testTreeCache() {
		Configuration c = new Configuration();
	    c.setInvocationBatchingEnabled(true);
		TreeCache<Object, Object> cache = new TreeCacheFactory().createTreeCache(new DefaultCacheManager(c).getCache());
		
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key1","TRADE1");
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key2","TRADE2");
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key3","TRADE3");
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key4","TRADE4");
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key5","TRADE5");
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key6","TRADE6");
		cache.put(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key7","TRADE7");
		Object object = cache.get(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")),"key7");
		assertNotNull(object);
		Map<Object, Object> data = cache.getData(Fqn.fromRelativeFqn(getBase(), Fqn.fromString("TRADE")));
		assertNotNull(data);
	}
	
	private Fqn getBase() {
		return Fqn.fromString("SYSTEMSTATUS");
	}

}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the infinispan-issues mailing list