Package org.apache.geronimo.system.plugin

Examples of org.apache.geronimo.system.plugin.ServerArchiver


            kernel.getProxyManager().destroyProxy(installer);
        }
    }

    public File archive(String sourcePath, String destPath, Artifact artifact) throws ArchiverException, IOException {
        ServerArchiver archiver = getServerArchiver();
        try {
            return archiver.archive(sourcePath, destPath, artifact);
        } finally {
            kernel.getProxyManager().destroyProxy(archiver);
        }
    }
View Full Code Here


        String artifactId = request.getParameter("artifactId");
        String version = request.getParameter("version");
        String format = request.getParameter("format");

        PluginInstaller pluginInstaller = ManagementHelper.getManagementHelper(request).getPluginInstaller();
        ServerArchiver archiver = ManagementHelper.getManagementHelper(request).getArchiver();
        String[] configIds = request.getParameterValues("configId");

        PluginListType list = getServerPluginList(request, pluginInstaller);
        PluginListType installList = getPluginsFromIds(configIds, list);

        try {
            DownloadResults downloadResults = pluginInstaller.installPluginList("repository", relativeServerPath, installList);
            archiver.archive(relativeServerPath, "var/temp", new Artifact(groupId, artifactId, version, format));
        } catch (Exception e) {
            throw new PortletException("Could not assemble server", e);
        }
        return INDEX_MODE;
    }
View Full Code Here

            kernel.getProxyManager().destroyProxy(installer);
        }
    }

    public File archive(String sourcePath, String destPath, Artifact artifact) throws ArchiverException, IOException {
        ServerArchiver archiver = getServerArchiver();
        try {
            return archiver.archive(sourcePath, destPath, artifact);
        } finally {
            kernel.getProxyManager().destroyProxy(archiver);
        }
    }
View Full Code Here

        String format = request.getParameter("format");
       
        response.setRenderParameter("relativeServerPath",relativeServerPath);

        PluginInstaller pluginInstaller = ManagementHelper.getManagementHelper(request).getPluginInstaller();
        ServerArchiver archiver = ManagementHelper.getManagementHelper(request).getArchiver();
        String[] configIds = request.getParameterValues("configId");

        PluginListType list = getServerPluginList(request, pluginInstaller);
        PluginListType installList = getPluginsFromIds(configIds, list);
       

        try {
            DownloadResults downloadResults = pluginInstaller.installPluginList("repository", relativeServerPath, installList);
            archiver.archive(relativeServerPath, "var/temp", new Artifact(groupId, artifactId, version, format));
        } catch (Exception e) {
            throw new PortletException("Could not assemble server", e);
        }
        return ASSEMBLY_CONFIRM_MODE+BEFORE_ACTION;
    }
View Full Code Here

        String version = request.getParameter("version");
        String format = request.getParameter("format");
       

        PluginInstaller pluginInstaller = ManagementHelper.getManagementHelper(request).getPluginInstaller();
        ServerArchiver archiver = ManagementHelper.getManagementHelper(request).getArchiver();
        String[] configIds = request.getParameterValues("configId");

        PluginListType list = getServerPluginList(request, pluginInstaller);
        PluginListType installList = getPluginsFromIds(configIds, list);
       
       
        // if the targetPath doesn't end with "/" or "\", add one.
        if (targetPath.lastIndexOf("/") != targetPath.length()-1){
            if (targetPath.lastIndexOf("\\") != targetPath.length()-1){
                targetPath = targetPath + "/";
            }
        }
       
        String targetBasePath = targetPath + groupId +"/";
        String targetAssemblyPath = targetBasePath + artifactId+"-"+version;
        String targetArchivePath = targetBasePath;
       
        try {
            DownloadResults downloadResults = pluginInstaller.installPluginList("repository", targetAssemblyPath, installList);
            archiver.archive(targetAssemblyPath, targetArchivePath, new Artifact(groupId, artifactId, version, format));
        } catch (Exception e) {
            throw new PortletException("Could not assemble server", e);
        }
       
        response.setRenderParameter("assemblyFileLocation", targetBasePath);
View Full Code Here

            kernel.getProxyManager().destroyProxy(installer);
        }
    }

    public File archive(String sourcePath, String destPath, Artifact artifact) throws ArchiverException, IOException {
        ServerArchiver archiver = getServerArchiver();
        try {
            return archiver.archive(sourcePath, destPath, artifact);
        } finally {
            kernel.getProxyManager().destroyProxy(archiver);
        }
    }
View Full Code Here

            kernel.getProxyManager().destroyProxy(installer);
        }
    }

    public File archive(String sourcePath, String destPath, Artifact artifact) throws ArchiverException, IOException {
        ServerArchiver archiver = getServerArchiver();
        try {
            return archiver.archive(sourcePath, destPath, artifact);
        } finally {
            kernel.getProxyManager().destroyProxy(archiver);
        }
    }
View Full Code Here

        String format = request.getParameter("format");
       
        response.setRenderParameter("relativeServerPath",relativeServerPath);

        PluginInstaller pluginInstaller = ManagementHelper.getManagementHelper(request).getPluginInstaller();
        ServerArchiver archiver = ManagementHelper.getManagementHelper(request).getArchiver();
        String[] configIds = request.getParameterValues("configId");

        PluginListType list = getServerPluginList(request, pluginInstaller);
        PluginListType installList = getPluginsFromIds(configIds, list);
       

        try {
            DownloadResults downloadResults = pluginInstaller.installPluginList("repository", relativeServerPath, installList);
            archiver.archive(relativeServerPath, "var/temp", new Artifact(groupId, artifactId, version, format));
        } catch (Exception e) {
            throw new PortletException("Could not assemble server", e);
        }
        return ASSEMBLY_CONFIRM_MODE+BEFORE_ACTION;
    }
View Full Code Here

            kernel.getProxyManager().destroyProxy(installer);
        }
    }

    public File archive(String sourcePath, String destPath, Artifact artifact) throws IOException {
        ServerArchiver archiver = getServerArchiver();
        try {
            return archiver.archive(sourcePath, destPath, artifact);
        } finally {
            kernel.getProxyManager().destroyProxy(archiver);
        }
    }
View Full Code Here

            kernel.getProxyManager().destroyProxy(installer);
        }
    }

    public File archive(String sourcePath, String destPath, Artifact artifact) throws IOException {
        ServerArchiver archiver = getServerArchiver();
        try {
            return archiver.archive(sourcePath, destPath, artifact);
        } finally {
            kernel.getProxyManager().destroyProxy(archiver);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.geronimo.system.plugin.ServerArchiver

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.