File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JBoss/WildFly and the fly likes Startup/Shutdown class in JBOSS 4.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "Startup/Shutdown class in JBOSS 4.0" Watch "Startup/Shutdown class in JBOSS 4.0" New topic
Author

Startup/Shutdown class in JBOSS 4.0

Rajesh MadhanGopal
Ranch Hand

Joined: Jan 19, 2006
Posts: 69
Hi

Could someone tell me how to write a simple startup class which would start when i start the app server.

The following are the steps i performed :

1. Wrote a Mbean interface.
2. Wrote a Startup class implementing the Mbean interface.
3. Created a JAR of the 2 class files.

Now, where do i add the JAR file and also where is the jboss-service.xml in which i need to make an entry for the MBean.


Thanks<br />Rajesh
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17249
    
    6

jboss-service is located in the server/yourConfig/conf directory.

You would place the jar file in the deploy directory of server/yourConfig directory. "yourConfig" is whatever you are using. It might be minimal, default, all, or a copy of one of those that you customized for your environment (which is highly recommended to do).

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Startup/Shutdown class in JBOSS 4.0
 
Similar Threads
MBean's depends option in Jboss
MBeans On Weblogic
another jmx/jboss question - abt dynamic mbeans and accessing properties file
MBeans in WebLogic
Automatically start local application after JBoss started