[jboss-user] [Installation, Configuration & DEPLOYMENT] - Question about JBoss AS 4.2 and @PostConsruct annotation

AceFrehley do-not-reply at jboss.com
Fri Dec 5 10:25:47 EST 2008


Hello. I have a JSF application that I have deployed with a simple managed bean. I added the @PostConstruct annotation to a method of the managed bean as follows, but the method never fires. I even removed my my Logger and used a System.out.println to simplify further.

Is @PostConstruct supported by JBoss AS 4.2? I don't want to waste a lot of time on this if it is not.

Thank you.


  | 
  | @PostConstruct
  | public void initialize()
  | {
  | 	System.out.println("TEST: POSTCONSTRUCT FIRED");
  | }
  | 
  | faces-config.xml:
  | 
  |  <managed-bean>
  |  <managed-bean-name>bean</managed-bean-name>
  |  <managed-bean-class>demo.Bean</managed-bean-class>
  |  <managed-bean-scope>request</managed-bean-scope>
  |  <managed-property>
  |  <property-name>text</property-name>
  |  <value>#{param.text}</value>
  |  </managed-property>
  |  </managed-bean>
  | 
  | 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4194651#4194651

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4194651



More information about the jboss-user mailing list