Skip to main content
Version: Deploy 23.3

JBoss AS plugin

This topic describes the Deploy JBoss Application Server (AS) plugin that adds the capability to manage deployments and resources on a JBoss Application Server.

It can be used to deploy and undeploy application artifacts, data sources, and other JMS resources. You can extend the plugin to support more deployment options or management of new artifacts and resources on JBoss Application Server.

For information, see JBoss Application Server Plugin Reference.

Features

  • Deploy application artifacts:
    • Enterprise application (EAR)
    • Web application (WAR)
  • Deploy JBoss-specific artifacts:
    • Service Archive (SAR)
    • Resource Archive (RAR)
    • Hibernate Archive (HAR)
    • Aspect archive (AOP)
  • Deploy resources:
    • Datasource
    • JMS Queue
    • JMS Topic
  • Discover middleware containers

Use in deployment packages

This is a sample deployit-manifest.xml file that can be used to create a deployment package. It contains declarations for a jbossas.Ear, a jbossas.DataSourceSpec, and JMS resources.

<?xml version="1.0" encoding="UTF-8"?>
<udm.DeploymentPackage version="1.0" application="SampleApp">
<deployables>
<jbossas.QueueSpec name="testQueue">
<jndiName>jms/testQueue</jndiName>
</jbossas.QueueSpec>
<jbossas.ConfigurationFolder name="testConfigFolder" file="testConfigFolder/">
<scanPlaceholders>true</scanPlaceholders>
</jbossas.ConfigurationFolder>
<jbossas.TopicSpec name="testTopic">
<jndiName>jms/testTopic</jndiName>
</jbossas.TopicSpec>
<jbossas.TransactionalDatasourceSpec name="testDatasource">
<jndiName>jdbc/sampleDatasource</jndiName>
<userName>{{DATABASE_USERNAME}}</userName>
<password>{{DATABASE_PASSWORD}}</password>
<connectionUrl>jdbc:mysql://localhost/test</connectionUrl>
<driverClass>com.mysql.jdbc.Driver</driverClass>
<connectionProperties />
</jbossas.TransactionalDatasourceSpec>
<jbossas.ConfigurationFile name="testConfigFiles" file="testConfigFiles/testConfigFile.xml">
<scanPlaceholders>true</scanPlaceholders>
</jbossas.ConfigurationFile>
<jee.Ear name="PetClinic" file="PetClinic/PetClinic.ear">
<scanPlaceholders>false</scanPlaceholders>
</jee.Ear>
</deployables>
</udm.DeploymentPackage>

Deploying applications

By default, Deploy deploys the application artifacts and resource specifications, datasource, queues, topics etc. to the deploy directory in the server configuration. If the server configuration is set to default, which is the default value for server name, the artifact is copied to ${JBOSS_HOME}/server/default/deploy. Also, the server is stopped before copying the artifact and then started again. These configurations are customizable to suit specific scenarios.

Creating JMS resources

When creating JMS resources such as JMS queues and JMS topics for JBoss Application Server 6, only the JNDI name is used. Other properties such as RedeliveryDelay, MaxDeliveryAttempts, etc. are not used, even if they are defined and set on CI in synthetic.xml. You can define these properties by editing the global server configuration at %JBOSS_HOME%/server/<configuration>/deploy/hornetq/hornetq-jms.xml.