Class AffectedDeploymentOverlay


  • public class AffectedDeploymentOverlay
    extends Object
    Utility class for finding and updating deployments affected by an overlay change. This is where the magic of getting deployments affected by an overlay is happening.
    Author:
    Emmanuel Hugonnet (c) 2017 Red Hat, inc.
    • Method Detail

      • listAllLinks

        public static Set<String> listAllLinks​(OperationContext context,
                                               String overlay)
        Returns all the deployment runtime names associated with an overlay accross all server groups.
        Parameters:
        context - the current OperationContext.
        overlay - the name of the overlay.
        Returns:
        all the deployment runtime names associated with an overlay accross all server groups.
      • listLinks

        public static Set<String> listLinks​(OperationContext context,
                                            PathAddress overlayAddress)
        Returns all the deployment runtime names associated with an overlay.
        Parameters:
        context - the current OperationContext.
        overlayAddress - the address for the averlay.
        Returns:
        all the deployment runtime names associated with an overlay.
      • redeployLinksAndTransformOperationForDomain

        public static void redeployLinksAndTransformOperationForDomain​(OperationContext context,
                                                                       Set<String> runtimeNames,
                                                                       org.jboss.dmr.ModelNode removeOperation)
                                                                throws OperationFailedException
        It will look for all the deployments (in every server-group) with a runtimeName in the specified list of runtime names and then transform the operation so that every server in those server groups will redeploy the affected deployments.
        Parameters:
        removeOperation -
        context -
        runtimeNames -
        Throws:
        OperationFailedException
        See Also:
        #transformOperation
      • redeployLinksAndTransformOperation

        public static void redeployLinksAndTransformOperation​(OperationContext context,
                                                              org.jboss.dmr.ModelNode removeOperation,
                                                              PathAddress deploymentsRootAddress,
                                                              Set<String> runtimeNames)
                                                       throws OperationFailedException
        It will look for all the deployments under the deploymentsRootAddress with a runtimeName in the specified list of runtime names and then transform the operation so that every server having those deployments will redeploy the affected deployments.
        Parameters:
        removeOperation -
        context -
        deploymentsRootAddress -
        runtimeNames -
        Throws:
        OperationFailedException
        See Also:
        #transformOperation
      • listDeployments

        public static Set<String> listDeployments​(Resource deploymentRootResource,
                                                  Set<String> runtimeNames)
        Returns the deployment names with the specified runtime names at the specified deploymentRootAddress.
        Parameters:
        deploymentRootResource -
        runtimeNames -
        Returns:
        the deployment names with the specified runtime names at the specified deploymentRootAddress.