How to deploy an application on JBoss AS

User Rating: 4 / 5

Star ActiveStar ActiveStar ActiveStar ActiveStar Inactive
 
A short tutorial for JBoss AS beginners which explains how to deploy an application.

This information is related to JBoss AS 4/5/6 releases. In the new JBoss AS 7, deployment can be pursued with different instruments. See this JBoss AS 7 introduction for more information about it.

 Deploying an application with JBoss AS is a straightforward task. If you have access to the host where JBoss is installed you can simply copy the application (.jar , .war, .ear etc) into the JBOSS_HOME/server/<your config>/deploy folder.

Simply substitute <your config> with your server configuration (default, all, minimal, web, standard)

An application can be deployed in two flavours:

  • Packed archive (.jar , .war, .ear)
  • Exploded directory (directory whose name ends with .jar, .war, .ear)

 

 It is advised to use exploded directory for development and packed archive for production since you can do partial redeployments of the application  with exploded directory.

 

For example if you are deploying a Web application and you want to update just one Servlet, with exploded directory you can do it without redeploying the application.

Also remember that simply "touching" a Java EE configuration file (web.xml , application.xml) causes the application to redeploy. In the same way, touching a JBoss specific configuration file (like jboss-web.xml) will cause the application to redeploy as well.

Related articles available on mastertheboss.com

How to configure JBoss to disable hot deployment ?

On JBoss AS 7 and WildFly the default rule is that archived appli

How do I make sure my MBean is deployed after my EJB ?

  If your MBean is dependant on another resource, supposing cont

How do I change the default lib directory in an ear file?

  Supposing you have an Enterprise application which has been pa

How to let JBoss deploy an application after other apps?

  If you are running JBoss AS 7 or WildFly check the following t

How to deploy an application temporarly with JBoss ?

One way to do it, is using the jboss.system:service=MainDeployer

How to add a custom JBoss archive in an Ear ?

JBoss custom archives (like .sar or .har) are not recognized by t

Follow us on Twitter