Skip to content

Commit

Permalink
WFLY-8697 ApplicationContextProcessor doesn't cleanup Attachments.APP…
Browse files Browse the repository at this point in the history
…LICATION_CONTEXT_CONFIG on undeploy()
  • Loading branch information
rhusar committed May 6, 2017
1 parent bb0a90c commit 5abd116
Showing 1 changed file with 4 additions and 4 deletions.
Expand Up @@ -48,7 +48,7 @@ public class ApplicationContextProcessor implements DeploymentUnitProcessor {
* Add a ContextService for this module.
*
* @param phaseContext the deployment unit context
* @throws org.jboss.as.server.deployment.DeploymentUnitProcessingException
* @throws DeploymentUnitProcessingException
*/
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
Expand All @@ -66,11 +66,11 @@ public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitPro
.addDependency(applicationContextServiceName, ServiceBasedNamingStore.class, applicationNameBinder.getNamingStoreInjector())
.addInjection(applicationNameBinder.getManagedObjectInjector(), new ValueManagedReferenceFactory(Values.immediateValue(moduleDescription.getApplicationName())))
.install();
deploymentUnit.addToAttachmentList(org.jboss.as.server.deployment.Attachments.JNDI_DEPENDENCIES,appNameServiceName);
deploymentUnit.addToAttachmentList(org.jboss.as.server.deployment.Attachments.JNDI_DEPENDENCIES, appNameServiceName);
deploymentUnit.putAttachment(Attachments.APPLICATION_CONTEXT_CONFIG, applicationContextServiceName);
}

public void undeploy(DeploymentUnit context) {

public void undeploy(DeploymentUnit deploymentUnit) {
deploymentUnit.removeAttachment(Attachments.APPLICATION_CONTEXT_CONFIG);
}
}

0 comments on commit 5abd116

Please sign in to comment.