aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ARIES-1474) blueprint-maven-plugin: Inherited init/destroy methods are ignored
Date Tue, 12 Jan 2016 14:07:40 GMT

    [ https://issues.apache.org/jira/browse/ARIES-1474?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15093919#comment-15093919
] 

ASF GitHub Bot commented on ARIES-1474:
---------------------------------------

Github user samwright closed the pull request at:

    https://github.com/apache/aries/pull/33


> blueprint-maven-plugin: Inherited init/destroy methods are ignored
> ------------------------------------------------------------------
>
>                 Key: ARIES-1474
>                 URL: https://issues.apache.org/jira/browse/ARIES-1474
>             Project: Aries
>          Issue Type: Bug
>          Components: Blueprint
>    Affects Versions: blueprint-maven-plugin-1.3.0
>            Reporter: Sam Wright
>            Assignee: Christian Schneider
>             Fix For: blueprint-maven-plugin-1.4.0
>
>
> Current behaviour:
> {code}
> public class A {
>     @PostConstruct
>     public void init() {}
>     @PreDestroy
>     public void destroy() {}
> }
> public class B extends A {}
> public class C extends B {
>     @Override
>     public void init() {}
>     @PostConstruct
>     public void secondInit()
> }
> {code}
> Three problems:
> * The A.destroy() method is ignored
> * The C.init() method overrides A.init() without the @PostConstruct annotation, but is
still taken to be the init method. This means the subclass can't disable a superclass' init
method.
> * The C.secondInit() method is silently ignored because another init method is found
first. 
> Patch incoming...



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message