commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Clark (JIRA)" <j...@apache.org>
Subject [jira] [Created] (JCS-102) JCS.getGroupKeys() always triggers a\ ClassCastException
Date Sun, 23 Dec 2012 21:44:12 GMT
Robert Clark created JCS-102:
--------------------------------

             Summary: JCS.getGroupKeys() always triggers a\ ClassCastException
                 Key: JCS-102
                 URL: https://issues.apache.org/jira/browse/JCS-102
             Project: Commons JCS
          Issue Type: Bug
          Components: Composite Cache
    Affects Versions: jcs-2.0.0
            Reporter: Robert Clark


Using SVN version build Dec 20, 2012:

This code:

{code:java}
JCS<Long, String> jcs = JCS.getInstance("the region");
jcs.getGroupKeys("the group");
jcs.putInGroup(Long.valueOf(1), "the group", "some value");
jcs.getGroupKeys("the group");
{code}

will trigger an exception on the *second* getGroupKeys() call (when there is actually something
in the cache)

{noformat}
Exception in thread "main" java.lang.ClassCastException: java.lang.Long cannot be cast to
org.apache.jcs.engine.control.group.GroupAttrName
     [java] 	at org.apache.jcs.access.GroupCacheAccess.getGroupKeys(GroupCacheAccess.java:205)
     [java] 	at my.sample.code.Main.main(Main.java:108)
{noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message