Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 1.3.2 (Gosling SR2)
-
Fix Version/s: 1.3.5 (Gosling SR5), 1.4.2 (Hopper SR2), 1.5 M1 (Ingalls)
-
Component/s: Core
-
Labels:None
-
Last commented by a User:true
Description
Current CDI support sometimes fails, because it stores CassandraOperation instances in a map with String key representing a set of Qualifiers:
cassandraOperationsMap.put(bean.getQualifiers().toString(), ((Bean<CassandraOperations>) bean));
However, Set doesn't define iteration order (or even String representation for that matter), so with 2+ Qualifiers there's a good chance to get them in the wrong order and fail to find operations:
Bean<CassandraOperations> cassandraOperationsBean = this.cassandraOperationsMap.get(qualifiers.toString());
Example:
[@javax.enterprise.inject.Default(), @javax.enterprise.inject.Any()]
!=
[@javax.enterprise.inject.Any(), @javax.enterprise.inject.Default()]
Attachments
Issue Links
- relates to
-
DATACOUCH-203 CDI support can fail due to Set.toString() used as Map key
-
- Closed
-
-
DATAES-234 CDI support can fail due to Set.toString() used as Map key
-
- Closed
-
-
DATASOLR-276 CDI support can fail due to Set.toString() used as Map key
-
- Waiting for Review
-