[ https://issues.apache.org/jira/browse/OWB-1207?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Struberg resolved OWB-1207. -------------------------------- Resolution: Fixed Assignee: Mark Struberg Fix Version/s: 2.0.1 Txs for the report! I've slightly tweaked our impl to behave consistent while still passing the TCK. > Inconsistent behavior of the instance behind CDI.current() > ---------------------------------------------------------- > > Key: OWB-1207 > URL: https://issues.apache.org/jira/browse/OWB-1207 > Project: OpenWebBeans > Issue Type: Bug > Reporter: John D. Ament > Assignee: Mark Struberg > Fix For: 2.0.1 > > > The behavior of CDI.current() is a bit odd, and seems to have a bug in it. > Suppose I have the following: > {code} > Instance x = CDI.current().select(SomeClass, someQualifiers); > Instance y = CDI.current().select(SomeClass).select(someQualifiers) > {code} > Those two instances should be pointing to same set of beans, have the same > set of qualifiers, but they do not. x will in fact have an extra Default > qualifier that y does not have. The default qualifier is not expected here. > This happens because the return value of `instance()` in `OwbCDI` selects a > default qualifier, and the method taking var args for type and annotations > does a merge, whereas the second method of selecting just qualifiers does a > replacement. -- This message was sent by Atlassian JIRA (v6.4.14#64029)