deploymentName = createDeploymentName(archive.getName());
try {
// Build up the POST form to send to Glassfish
final FormDataMultiPart form = new FormDataMultiPart();
form.field("target", this.configuration.getTarget(), MediaType.TEXT_PLAIN_TYPE);
form.field("operation", DELETE_OPERATION, MediaType.TEXT_PLAIN_TYPE);
glassFishClient.doUndeploy(this.deploymentName, form);
} catch (GlassFishClientException e) {
throw new DeploymentException("Could not undeploy " + archive.getName(), e);
}
}