org.codehaus.mojo.jboss
Class WaitAppStartMojo

java.lang.Object
  extended by org.apache.maven.plugin.AbstractMojo
      extended by org.codehaus.mojo.jboss.AbstractJBossServerMojo
          extended by org.codehaus.mojo.jboss.StartMojo
              extended by org.codehaus.mojo.jboss.StartAndWaitMojo
                  extended by org.codehaus.mojo.jboss.WaitAppStartMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

public class WaitAppStartMojo
extends StartAndWaitMojo

Waits until an app is started.

Since:
1.5.0
Author:
Vinicius Kopcheski
Requires a Maven project to run:
false
Is defined by the goal name:
wait-app-start

Field Summary
protected  String earName
           
 
Fields inherited from class org.codehaus.mojo.jboss.StartAndWaitMojo
hostName, namingPort, ONE_SECOND, retry, retryWait, timeout
 
Fields inherited from class org.codehaus.mojo.jboss.StartMojo
options, startOptions, STARTUP_COMMAND
 
Fields inherited from class org.codehaus.mojo.jboss.AbstractJBossServerMojo
jbossHome, serverName
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
WaitAppStartMojo()
           
 
Method Summary
 void execute()
          Main plugin execution.
protected  boolean isAppStarted(javax.management.MBeanServerConnection server)
          Check if the server has finished starting the app.
 
Methods inherited from class org.codehaus.mojo.jboss.StartAndWaitMojo
getInitialContext, isStarted
 
Methods inherited from class org.codehaus.mojo.jboss.AbstractJBossServerMojo
checkConfig, getPassword, getUsername, launch, launchUnixScript, launchWindowsBatch
 
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

earName

protected String earName
Is defined by:
expression:
${jboss.earName}
default-value:
Constructor Detail

WaitAppStartMojo

public WaitAppStartMojo()
Method Detail

execute

public void execute()
             throws org.apache.maven.plugin.MojoExecutionException
Description copied from class: StartAndWaitMojo
Main plugin execution.

Specified by:
execute in interface org.apache.maven.plugin.Mojo
Overrides:
execute in class StartAndWaitMojo
Throws:
org.apache.maven.plugin.MojoExecutionException

isAppStarted

protected boolean isAppStarted(javax.management.MBeanServerConnection server)
                        throws Exception
Check if the server has finished starting the app. Will throw one of several exceptions if the server connection fails.

Parameters:
server - The connection to the server
Returns:
true if the app is started
Throws:
Exception


Copyright © 2005-2012 Codehaus. All Rights Reserved.