Examples of DeploymentEngine


Examples of org.apache.axis2.deployment.DeploymentEngine

                     ServerContextInformation serverContextInformation) {
       
        Object context = serverContextInformation.getServerContext();
        if (context instanceof ConfigurationContext) {
            AxisConfiguration axisCfg = ((ConfigurationContext) context).getAxisConfiguration();
            DeploymentEngine deploymentEngine = (DeploymentEngine) axisCfg.getConfigurator();
            // File carbonHome = new File(System.getProperty(ServerConstants.CARBON_HOME));
            // subjected to change
            String carbonRepoPath = axisCfg.getRepository().getPath();
            String mediatorsPath = carbonRepoPath + File.separator + "mediators";
            String extensionsPath = carbonRepoPath + File.separator + "extensions";
            ExtensionDeployer deployer = new ExtensionDeployer();
            deploymentEngine.addDeployer(deployer, mediatorsPath, "xar");
            deploymentEngine.addDeployer(deployer, extensionsPath, "xar");
            deploymentEngine.addDeployer(deployer, mediatorsPath, "jar");
            deploymentEngine.addDeployer(deployer, extensionsPath, "jar");

            this.currentConfigurationName = ((ConfigurationContext) context).
                    getAxisConfiguration().getParameterValue(
                    ServiceBusConstants.SYNAPSE_CURRENT_CONFIGURATION).toString();
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

        } while (isDeploymentSchedulerRunning);
        log.info("All deployment tasks have been completed.");
    }

    private boolean isDeploymentSchedulerRunning(ConfigurationContext configurationContext) {
        DeploymentEngine deploymentEngine =
                (DeploymentEngine) configurationContext.getAxisConfiguration().getConfigurator();
        return deploymentEngine.isDeploymentTaskRunning();
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

     * @param synapseEnvironment SynapseEnvironment to which this deployer belongs
     */
    private void unregisterDeployer(AxisConfiguration axisConfig, SynapseEnvironment synapseEnvironment)
            throws TenantAwareLoadBalanceEndpointException {
        if (axisConfig != null) {
            DeploymentEngine deploymentEngine = (DeploymentEngine) axisConfig.getConfigurator();
            String synapseConfigPath = ServiceBusUtils.getSynapseConfigAbsPath(
                    synapseEnvironment.getServerContextInformation());
            String endpointDirPath = synapseConfigPath
                    + File.separator + MultiXMLConfigurationBuilder.ENDPOINTS_DIR;
            deploymentEngine.removeDeployer(
                    endpointDirPath, ServiceBusConstants.ARTIFACT_EXTENSION);
        }
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

     * @param synapseEnvironment SynapseEnvironment to which this deployer belongs
     */
    private void registerDeployer(AxisConfiguration axisConfig, SynapseEnvironment synapseEnvironment)
            throws TenantAwareLoadBalanceEndpointException {
        SynapseConfiguration synCfg = synapseEnvironment.getSynapseConfiguration();
        DeploymentEngine deploymentEngine = (DeploymentEngine) axisConfig.getConfigurator();
        SynapseArtifactDeploymentStore deploymentStore = synCfg.getArtifactDeploymentStore();

        String synapseConfigPath = ServiceBusUtils.getSynapseConfigAbsPath(
                synapseEnvironment.getServerContextInformation());
        String endpointDirPath = synapseConfigPath
                + File.separator + MultiXMLConfigurationBuilder.ENDPOINTS_DIR;

        for (Endpoint ep : synCfg.getDefinedEndpoints().values()) {
            if (ep.getFileName() != null) {
                deploymentStore.addRestoredArtifact(
                        endpointDirPath + File.separator + ep.getFileName());
            }
        }
        deploymentEngine.addDeployer(
                new EndpointDeployer(), endpointDirPath, ServiceBusConstants.ARTIFACT_EXTENSION);
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

     * @param axisConfig AxisConfiguration to which this deployer belongs
     * @param synapseEnvironment SynapseEnvironment to which this deployer belongs
     */
    private void unregisterDeployer(AxisConfiguration axisConfig, SynapseEnvironment synapseEnvironment)
            throws LocalEntryAdminException {
        DeploymentEngine deploymentEngine = (DeploymentEngine) axisConfig.getConfigurator();
        String synapseConfigPath = ServiceBusUtils.getSynapseConfigAbsPath(
                synapseEnvironment.getServerContextInformation());
        String entriesDirPath = synapseConfigPath
                + File.separator + MultiXMLConfigurationBuilder.LOCAL_ENTRY_DIR;
        deploymentEngine.removeDeployer(
                entriesDirPath, ServiceBusConstants.ARTIFACT_EXTENSION);
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

     * @param synapseEnvironment SynapseEnvironment to which this deployer belongs
     */
    private void registerDeployer(AxisConfiguration axisConfig, SynapseEnvironment synapseEnvironment)
            throws LocalEntryAdminException {
        SynapseConfiguration synCfg = synapseEnvironment.getSynapseConfiguration();
        DeploymentEngine deploymentEngine = (DeploymentEngine) axisConfig.getConfigurator();
        SynapseArtifactDeploymentStore deploymentStore = synCfg.getArtifactDeploymentStore();

        String synapseConfigPath = ServiceBusUtils.getSynapseConfigAbsPath(
                synapseEnvironment.getServerContextInformation());
        String entriesDirPath = synapseConfigPath
                + File.separator + MultiXMLConfigurationBuilder.LOCAL_ENTRY_DIR;

        for (Entry entry : synCfg.getDefinedEntries().values()) {
            if (entry.getFileName() != null) {
                deploymentStore.addRestoredArtifact(
                        entriesDirPath + File.separator + entry.getFileName());
            }
        }
        deploymentEngine.addDeployer(new LocalEntryDeployer(),
                entriesDirPath, ServiceBusConstants.ARTIFACT_EXTENSION);
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

        }
    }

    private void registerDeployer(AxisConfiguration axisConfig, SynapseEnvironment synEnv)
            throws ProxyAdminException {
        DeploymentEngine deploymentEngine = (DeploymentEngine) axisConfig.getConfigurator();
        SynapseArtifactDeploymentStore deploymentStore =
                synEnv.getSynapseConfiguration().getArtifactDeploymentStore();

        String synapseConfigPath = ServiceBusUtils.getSynapseConfigAbsPath(
                synEnv.getServerContextInformation());

        String proxyDirPath = synapseConfigPath
                + File.separator + MultiXMLConfigurationBuilder.PROXY_SERVICES_DIR;

        for (ProxyService proxyService : synEnv.getSynapseConfiguration().getProxyServices()) {
            if (proxyService.getFileName() != null) {
                deploymentStore.addRestoredArtifact(
                        proxyDirPath + File.separator + proxyService.getFileName());
            }
        }
        deploymentEngine.addDeployer(
                new ProxyServiceDeployer(), proxyDirPath, ServiceBusConstants.ARTIFACT_EXTENSION);
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

     * @param axisConfig AxisConfiguration to which this deployer belongs
     * @param synapseEnvironment SynapseEnvironment to which this deployer belongs
     */
    private void unregistryDeployer(AxisConfiguration axisConfig,
                                    SynapseEnvironment synapseEnvironment) {
        DeploymentEngine deploymentEngine = (DeploymentEngine) axisConfig.getConfigurator();
        String synapseConfigPath = ServiceBusUtils.getSynapseConfigAbsPath(
                synapseEnvironment.getServerContextInformation());
        String proxyDirPath = synapseConfigPath
                + File.separator + MultiXMLConfigurationBuilder.PROXY_SERVICES_DIR;
        deploymentEngine.removeDeployer(
                proxyDirPath, ServiceBusConstants.ARTIFACT_EXTENSION);
    }
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

    public ModuleDescription loadModulefromResources(String moduleName) throws AxisFault {
        ModuleDescription module;
        // trying to read from resources
        File file = new ArchiveReader().creatModuleArchivefromResource(moduleName,
                getRepository());
        module = new DeploymentEngine().buildModule(file, this);
        if (module != null) {
            // since it is a new module
            addModule(module);
        }
        return module;
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentEngine

    }

    public static ServiceContext createAdressedEnabledClientSide(
            ServiceDescription service)
            throws AxisFault {
        DeploymentEngine deploymentEngine = new DeploymentEngine();
        File file = new File(
                org.apache.axis2.Constants.TESTING_REPOSITORY +
                        "/modules/addressing.mar");
        TestCase.assertTrue(file.exists());
        ModuleDescription moduleDesc = deploymentEngine.buildModule(file);

        ConfigurationContextFactory efac = new ConfigurationContextFactory();
        ConfigurationContext sysContext =
                efac.buildClientConfigurationContext("target/test-resources/intregrationRepo");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.