Undeployment Preflight Check

When an application is undeployed, a preflight check can be performed to ensure that all dependencies are in sync.

The preflight check called optPreFlight ensures that all target applications, follower applications, and dependencies are in sync.

Note: There is also a preflight check when an application is deployed. It consists of two phases: optPreFlight and startPreFlight. Application undeployment does not use the startPreFlight phase.

The way in which the preflight check is done depends on whether you are using the Administrator GUI or the CLI, as described below.

Administrator GUI

When you undeploy an application from the Administrator GUI, the preflight check is performed by default. If any of the required applications or dependencies are determined to be out of sync during the preflight check, they are brought into sync before continuing.

Note, however, the preflight check can be skipped when undeploying from the Administrator GUI by choosing the Force Undeploy option. This should be done only in situations when you know for certain that all dependencies are in sync.

CLI

When an application undeployment is performed from the CLI, the preflight check is not performed by default. To perform the preflight check, "handleDependencies" must be specified in the AMXAdminTask options attribute. For example:

<target name="undeploy.app">

		<AMXAdminTask
			remote="true" 
   propsFile="${instanceProperties}"
   action="undeploy"
			dataFile="${dataFile}"
   objectSelector="Environment//Application"
			force="false"
			failOnError="true"
			options="handleDependencies"/>
	</target>

For more information about the available options, see Understanding AMXAdminTask.

Note: If, during the preflight check (optPreflight), it detects applications that are out-of-sync, it will sync them before proceeding with the undeployment.