users@glassfish.java.net

_at_PostConstruct not being called

From: <glassfish_at_javadesktop.org>
Date: Fri, 05 Feb 2010 16:02:10 PST

Consider the following simple bean:

@ApplicationScoped
public class Foobar {
    
    @PostConstruct
    public void initialize() {
        ...
    }

}

When deployed on Glassfish v3, the @javax.annotation.PostConstruct method is not being fired. This bean is working as expected otherwise (so I don't think this is a basic JEE6 configuration issue). Is there something I'm missing about the conditions under which this event is supposed to occur? I thought JSR316 now enabled these lifecycle methods to be fired on any managed bean?
[Message sent by forum member 'jeremynorris' (jnorris_at_pattern73.com)]

http://forums.java.net/jive/thread.jspa?messageID=385108