[infinispan-issues] [JBoss JIRA] (ISPN-8290) Mixed "capacity-factor" and "capacity" in org.infinispan.configuration.parsing.Attribute

Michael Pasternak (JIRA) issues at jboss.org
Tue Sep 12 10:13:00 EDT 2017


Michael Pasternak created ISPN-8290:
---------------------------------------

             Summary: Mixed "capacity-factor" and "capacity" in org.infinispan.configuration.parsing.Attribute
                 Key: ISPN-8290
                 URL: https://issues.jboss.org/browse/ISPN-8290
             Project: Infinispan
          Issue Type: Bug
          Components: Configuration
    Affects Versions: 9.1.0.Final
            Reporter: Michael Pasternak


1. According to documentation in 9.1 and XSD schema should be two separate attributes in
type="tns:distributed-cache" "capacity" and "capacity-factor", however 
org.infinispan.configuration.parsing.Attribute enum using "capacity" name for CAPACITY_FACTOR enum entry, e.g CAPACITY_FACTOR("capacity"), what is causing parsing error when  "capacity-factor" is used in "distributed-cache" configuration

javax.xml.stream.XMLStreamException: ParseError at [row,col]:[14,96]
Message: Unexpected attribute 'capacity-factor' encountered

2. org.infinispan.configuration.parsing.Parser#parseDistributedCache:2106 uses CAPACITY_FACTOR (which was collected from "capacity" attribute) to map to
builder.clustering().hash().capacityFactor

this is misleading and one that not familiar with this bug, won't be able to set "capacity-factor"
in cache configuration:

<distributed-cache capacity-factor="...">
...
</distributed-cache>



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the infinispan-issues mailing list