Package org.glassfish.api.deployment

Examples of org.glassfish.api.deployment.OpsParams


    public void unload(OSGiDeployedBundle appContainer, DeploymentContext context) {
    }

    public void clean(DeploymentContext context) {
        try {
            OpsParams params = context.getCommandParameters(OpsParams.class);
            // we should clean for both undeployment and the failed deployment
            if (params.origin.isUndeploy() || params.origin.isDeploy()) {
                Bundle bundle = getApplicationBundle(context);
                bundle.uninstall();
                getPA().refreshPackages(new Bundle[]{bundle});
View Full Code Here


        return null;
    }

    public boolean prepare(DeploymentContext context) {
        File file = context.getSourceDir();
        OpsParams params = context.getCommandParameters(OpsParams.class);
        if (params.origin.isDeploy()) {
            assert(file.isDirectory());
            installBundle(makeBundleLocation(file));
        }
        return true;
View Full Code Here

        // Noting to generate yet!!
    }

    protected void cleanArtifacts(DeploymentContext dc) throws DeploymentException {
        // Drop tables if needed on undeploy.
        OpsParams params = dc.getCommandParameters(OpsParams.class);
        if (params.origin.isUndeploy() && isDas()) {

            boolean hasScopedResource = false;
            String appName = params.name();
            ApplicationInfo appInfo = applicationRegistry.get(appName);
            Application application = appInfo.getMetaData(Application.class);
            Set<BundleDescriptor> bundles = application.getBundleDescriptors();

             // Iterate through all the bundles of the app and collect pu references in referencedPus
View Full Code Here

           return validatorFactory;
       }

       @Override
       public boolean isJava2DBRequired() {
           OpsParams params = deploymentContext.getCommandParameters(OpsParams.class);
           // We only do java2db while being deployed on DAS. We do not do java2DB on load of an application or being deployed on an instance of a cluster
           return params.origin.isDeploy() && isDas;
       }
View Full Code Here

        // Noting to generate yet!!
    }

    protected void cleanArtifacts(DeploymentContext dc) throws DeploymentException {
        // Drop tables if needed on undeploy.
        OpsParams params = dc.getCommandParameters(OpsParams.class);
        if (params.origin.isUndeploy() && isDas()) {

            boolean hasScopedResource = false;
            String appName = params.name();
            ApplicationInfo appInfo = applicationRegistry.get(appName);
            Application application = appInfo.getMetaData(Application.class);
            Set<BundleDescriptor> bundles = application.getBundleDescriptors();

             // Iterate through all the bundles of the app and collect pu references in referencedPus
View Full Code Here

    public void unload(OSGiDeployedBundle appContainer, DeploymentContext context) {
    }

    public void clean(DeploymentContext context) {
        try {
            OpsParams params = context.getCommandParameters(OpsParams.class);
            // we should clean for both undeployment and the failed deployment
            if (params.origin.isUndeploy() || params.origin.isDeploy()) {
                Bundle bundle = getApplicationBundle(context);
                bundle.uninstall();
                getPA().refreshPackages(new Bundle[]{bundle});
View Full Code Here

        return null;
    }

    public boolean prepare(DeploymentContext context) {
        File file = context.getSourceDir();
        OpsParams params = context.getCommandParameters(OpsParams.class);
        if (params.origin.isDeploy()) {
            assert(file.isDirectory());
            installBundle(makeBundleLocation(file));
        }
        return true;
View Full Code Here

           return validatorFactory;
       }

       @Override
       public boolean isJava2DBRequired() {
           OpsParams params = deploymentContext.getCommandParameters(OpsParams.class);
           // We only do java2db while being deployed on DAS. We do not do java2DB on load of an application or being deployed on an instance of a cluster
           return params.origin.isDeploy() && isDas;
       }
View Full Code Here

        }
        return cid;
    }
    
    public static  void removeRoleMapper(DeploymentContext dc) {
        OpsParams params = dc.getCommandParameters(OpsParams.class);
        if (params.origin != OpsParams.Origin.undeploy) {
            return;
        }
        String appName = params.name();
        SecurityRoleMapperFactory factory = getRoleMapperFactory();
        factory.removeRoleMapper(appName);

    }
View Full Code Here

            appProps.setProperty(APP_UNIQUE_ID_PROP, uniqueAppId + "");
        } else {
            uniqueAppId = Long.parseLong(appProps.getProperty(APP_UNIQUE_ID_PROP));
        }

        OpsParams params = dc.getCommandParameters(OpsParams.class);
        if (params.origin.isDeploy()) {
            // KEEP_STATE is saved to AppProps in EjbApplication.stop
            String keepStateVal = (String) dc.getAppProps().get(EjbApplication.KEEP_STATE);
            if (keepStateVal != null) {
                // save KEEP_STATE to Application so subsequent to make it available
View Full Code Here

TOP

Related Classes of org.glassfish.api.deployment.OpsParams

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.