public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { if (phaseContext.getAttachment(Attachments.DEPLOYMENT_TYPE) == DeploymentType.EAR) { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); // Make sure the next phase of this EAR depends on this phase of not just the EAR but also all subdeployments for (DeploymentUnit subdeployment : deploymentUnit.getAttachmentList(SUB_DEPLOYMENTS)) { phaseContext.addToAttachmentList(NEXT_PHASE_DEPS, Services.deploymentUnitName(deploymentUnit.getName(), subdeployment.getName(), phaseContext.getPhase())); } } }
@Override public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); deploymentUnit.putAttachment(attachmentKey, descriptorPropertyReplacement); }
@Override public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { phaseContext.getDeploymentUnit().putAttachment(SecurityAttachments.SECURITY_ENABLED, true); phaseContext.getDeploymentUnit().addToAttachmentList(Attachments.ADDITIONAL_FACTORIES, SecurityContextHandleFactory.INSTANCE); }
private ServiceName getProfileServiceName(final DeploymentPhaseContext phaseContext) { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); final DeploymentUnit parentDeploymentUnit = deploymentUnit.getParent(); if (parentDeploymentUnit != null) { return parentDeploymentUnit.getAttachment(EjbDeploymentAttachmentKeys.EJB_REMOTING_PROFILE_SERVICE_NAME); } else { return deploymentUnit.getAttachment(EjbDeploymentAttachmentKeys.EJB_REMOTING_PROFILE_SERVICE_NAME); } }
@Override public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { // Clean up job XML resolvers phaseContext.getDeploymentUnit().removeAttachment(BatchAttachments.JOB_XML_RESOLVER); // Clean jboss-all meta-data phaseContext.getDeploymentUnit().removeAttachment(BatchAttachments.BATCH_ENVIRONMENT_META_DATA); // Remove the JobOperatorService from the deployment unit phaseContext.getDeploymentUnit().removeAttachment(BatchAttachments.JOB_OPERATOR); }
public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { DeploymentUnit depUnit = phaseContext.getDeploymentUnit(); String depName = depUnit.getName().toLowerCase(Locale.ENGLISH); if (depName.endsWith(WAR_EXTENSION)) { MountExplodedMarker.setMountExploded(depUnit); } }
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { // Always add system property resolver phaseContext.getDeploymentUnit().addToAttachmentList(Attachments.DEPLOYMENT_PROPERTY_RESOLVERS, SystemPropertyResolver.INSTANCE); }
/** * Mark the deployment as a CDI one. * * @param deployment to be marked */ public static void mark(final DeploymentUnit deployment) { if (deployment.getParent() != null) { deployment.getParent().putAttachment(ATTACHMENT_KEY, true); } else { deployment.putAttachment(ATTACHMENT_KEY, true); } }
public static boolean isIIOPDeployment(final DeploymentUnit deploymentUnit) { final Boolean val = deploymentUnit.getAttachment(ATTACHMENT_KEY); return val != null && val; } }
@Override public void undeploy(DeploymentUnit deploymentUnit) { deploymentUnit.removeAttachment(WeldAttachments.BEAN_DEFINING_ANNOTATIONS); } }
@Override public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); deploymentUnit.putAttachment(attachmentKey, annotationPropertyReplacement); }
@Override public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); deploymentUnit.removeAttachment(EjbDeploymentAttachmentKeys.EJB_INJECTIONS); deploymentUnit.removeAttachment(EjbDeploymentAttachmentKeys.APPLICATION_EXCEPTION_DETAILS); deploymentUnit.removeAttachment(EjbDeploymentAttachmentKeys.EJB_JAR_DESCRIPTION); deploymentUnit.removeAttachment(EjbDeploymentAttachmentKeys.EJB_JAR_METADATA); }
/** * returns true if the {@link DeploymentUnit} has a beans.xml in any of it's resource roots, * or is a top level deployment that contains sub-deployments that are weld deployments. */ public static boolean isWeldDeployment(DeploymentUnit unit) { return unit.getAttachment(MARKER) != null; }
@Override public void undeploy(DeploymentUnit deploymentUnit) { deploymentUnit.removeAttachment(WeldAttachments.CLASSES_RESOURCE_ROOT); deploymentUnit.removeAttachment(ExplicitBeanArchiveMetadataContainer.ATTACHMENT_KEY); }
@Override public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { // add the external contexts to every DU attachments phaseContext.getDeploymentUnit().putAttachment(Attachments.EXTERNAL_CONTEXTS, externalContexts); }
@Override public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); deploymentUnit.removeAttachment(Attachments.EE_APPLICATION_CLASSES_DESCRIPTION); deploymentUnit.removeAttachment(Attachments.EE_APPLICATION_DESCRIPTION); deploymentUnit.removeAttachment(Attachments.EE_MODULE_CONFIGURATION); deploymentUnit.removeAttachment(Attachments.EE_MODULE_DESCRIPTION); deploymentUnit.removeAttachment(Attachments.MODULE_DEPLOYMENT_DESCRIPTOR_ENVIRONMENT); }
public void undeploy(DeploymentUnit deploymentUnit) { deploymentUnit.removeAttachment(Attachments.FINAL_PROPERTY_REPLACER); deploymentUnit.removeAttachment(Attachments.FINAL_PROPERTY_RESOLVER); deploymentUnit.removeAttachment(Attachments.DEPLOYMENT_PROPERTY_RESOLVERS); } }
@Override public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { phaseContext.getDeploymentUnit().putAttachment(UndertowAttachments.DEFAULT_SECURITY_DOMAIN, defaultSecurityDomain); }
private void installWebsockets(final DeploymentPhaseContext phaseContext, final WebSocketDeploymentInfo webSocketDeploymentInfo) { DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); deploymentUnit.putAttachment(UndertowAttachments.WEB_SOCKET_DEPLOYMENT_INFO, webSocketDeploymentInfo); }