Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Build the WAR file. The application must be packaged into a WAR file (Web Application Archive) on the server. Use the maven-war-plugin shipped with Jtest to package the application. The plugin automatically builds applications with the correct WAR structure. Execute the following command in the application directory:

Code Block
mvnmvnw clean install

Step 2: Deploying Example to an Application Server

...

  1. Run the following command to create an admin (Management role) user:
    Code Block
    ./add-user.sh
  2. Configure the secondary host. Edit the domain/configuration/host-slave.xml file (or copy the existing one from this directory).
    • Change the management port to '19999':
      Code Block
      <management-interfaces>
      	<native-interface security-realm="ManagementRealm">
      		<socket interface="management" port="${jboss.management.native.port:19999}"/>
      	</native-interface>
      </management-interfaces>
    • In the 'main-server-group', add the 'auto-start' option:
      Code Block
      <server name="server-one" group="main-server-group" auto-start="true"/>
  3. Start the Domain Controller (primary host):
    Code Block
    ./domain.sh --host-config=host-master.xml
  4. In a separate console, start the secondary host:
    Code Block
    ./domain.sh --host-config=host-slave.xml -Djboss.domain.master.address=127.0.0.1
  5. Deploy the application in one of the two ways:
  6. Verify that the application is running by visiting: http://localhost:8080/Calculator/

...

Execute the following command in the example application’s main directory:

Code Block
mvnmvnw package jtest:monitor

The goal generates the monitor.zip package, which contains artifacts necessary for collecting application coverage. 

...