-
1. Re: Adding logic during jboss application startup
rhusar Sep 6, 2011 9:46 AM (in response to jeevesdavid)1 of 1 people found this helpfulThat's one of the things that as far as I know the EE (Java Enterprise Edition 5) does not address. This means that the implementation will be container dependent. In JBoss you will have to use jboss-beans.xml or you can write your own MBean your application will depend on :-)
-
2. Re: Adding logic during jboss application startup
jaikiran Sep 6, 2011 9:56 AM (in response to rhusar)1 of 1 people found this helpfulHowever, in Java EE6 you can use a @Startup @Singleton bean to do that.
As for Java EE5, you can use a ServletContextListener (or even a load-on-startup servlet) to achieve the same.
-
3. Re: Adding logic during jboss application startup
jeevesdavid Sep 6, 2011 10:10 AM (in response to jaikiran)I think I can use ServletContextListener. So I guess there is nothing like the
ApplicationLifecycleListener interface we have in weblogic.
-
4. Re: Adding logic during jboss application startup
jeevesdavid Sep 6, 2011 10:12 AM (in response to rhusar)I can use the microcontainer approach as well - though it is new for me and might take longer to learn and implement well enough
-
5. Re: Adding logic during jboss application startup
rhusar Sep 6, 2011 10:15 AM (in response to jeevesdavid)Ideally if you could switch to EE6 with AS7 http://www.jboss.org/as7.html that would be the best ;-)