[
https://issues.apache.org/jira/browse/OWB-711?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13475556#comment-13475556
]
Arne Limburg commented on OWB-711:
----------------------------------
Daniel, thanks for reporting this.
But I am not really sure, if the requested behavior is correct in all cases:
>From your scenarios:
@Specializes Bean without overriding Observer-method: Observer gets called
@Specializes Bean with Overridden Observer-method: Overridden Observer gets
called twice
@Alternative @Specializes Bean without overriding Observer-method: Observer
gets called
@Alternative @Specializes Bean with overridden Observer-method: Overridden
Observer gets called twice
the second and the fourth scenario where bugs in OWB and are now fixed :-)
About the first and the third scenario, I am not sure about the correct
behavior. In fact this has nothing to do with specialization at all (btw. the
bug was not limited to specialization, too). The question is, if observer
methods are inherted at all. If that is the case, then the OWB behavior in the
first and third behavior are perfectly fine. But the spec is not clear about
this (chapter 4.2 misses a bullet point about this).
I have added a clarification request to the spec:
https://issues.jboss.org/browse/CDI-277
> Specialization does not deactivate Observer methods in parent class
> -------------------------------------------------------------------
>
> Key: OWB-711
> URL: https://issues.apache.org/jira/browse/OWB-711
> Project: OpenWebBeans
> Issue Type: Bug
> Components: Inheritance, Specialization
> Affects Versions: 1.1.5
> Reporter: Daniel Sachse
> Assignee: Arne Limburg
> Labels: patch
> Fix For: 1.1.7
>
> Attachments: Observer, Alternative, Specialize.patch
>
>
> I found some bugs regarding @Specializes and Observer methods.
> The scenarios:
> @Specializes Bean without overriding Observer-method: Observer gets called
> @Specializes Bean with Overridden Observer-method: Overridden Observer gets
> called twice
> @Alternative @Specializes Bean without overriding Observer-method: Observer
> gets called
> @Alternative @Specializes Bean with overridden Observer-method: Overridden
> Observer gets called twice
> I attached a patch file for the tests which do of course fail at the moment ;)
--
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