Package nl.tranquilizedquality.itest.cargo.exception

Examples of nl.tranquilizedquality.itest.cargo.exception.DeployException


            final URL remoteLocation = new URL(this.remoteLocation + containerConfigurationFile);
            final String installDir = containerHome + "server/";
            final ZipURLInstaller installer = new ZipURLInstaller(remoteLocation, installDir, installDir);
            installer.install();
        } catch (final MalformedURLException e) {
            throw new DeployException("Failed to download container!", e);
        }

        /*
         * Setup the system properties.
         */
 
View Full Code Here


                    final File destFile = new File("target/" + contextName + ".war");

                    try {
                        FileUtils.copyFile(srcFile, destFile);
                    } catch (final IOException e) {
                        throw new DeployException("Failed to copy WAR file: " + path, e);
                    }

                    path = destFile.getPath();
                }
            } else {
View Full Code Here

                    final File srcFile = new File(path);
                    final File destFile = new File("target/" + contextName + ".war");
                    try {
                        FileUtils.copyFile(srcFile, destFile);
                    } catch (final IOException e) {
                        throw new DeployException("Failed to copy WAR file: " + path, e);
                    }

                    path = destFile.getPath();
                }
            } else {
View Full Code Here

        DeployableType deployableType;
        /*
         * Check what kind of deployable it is.
         */
        if ("EAR".equals(type)) {
            throw new DeployException("Tomcat doesn't support EAR files!");
        } else if ("WAR".equals(type)) {
            deployableType = DeployableType.WAR;
        } else if ("EJB".equals(type)) {
            throw new DeployException("Tomcat doesn't support EJB files!");
        } else {
            // Default value is WAR file
            deployableType = DeployableType.WAR;
        }

View Full Code Here

                    final File destFile = new File("target/" + contextName + ".war");

                    try {
                        FileUtils.copyFile(srcFile, destFile);
                    } catch (final IOException e) {
                        throw new DeployException("Failed to copy WAR file: " + path, e);
                    }

                    path = destFile.getAbsolutePath();
                }
            } else {
View Full Code Here

        /*
         * Check what kind of deployable it is.
         */
        if ("EAR".equals(type)) {
            throw new DeployException("Jetty doesn't support EAR files!");
        } else if ("WAR".equals(type)) {
            deployableType = DeployableType.WAR;
        } else if ("EJB".equals(type)) {
            throw new DeployException("Jetty doesn't support EJB files!");
        } else {
            // Default value is WAR file
            deployableType = DeployableType.WAR;
        }

View Full Code Here

                    final File destFile = new File("target/" + contextName + ".war");

                    try {
                        FileUtils.copyFile(srcFile, destFile);
                    } catch (final IOException e) {
                        throw new DeployException("Failed to copy WAR file: " + path, e);
                    }

                    path = destFile.getPath();
                }
            } else {
View Full Code Here

            final URL remoteLocationUrl = new URL(this.remoteLocation + containerFile);
            installDir = StringUtils.substringBeforeLast(StringUtils.chomp(containerHome, "/"), "/");
            final ZipURLInstaller installer = new ZipURLInstaller(remoteLocationUrl, installDir, installDir);
            installer.install();
        } catch (final MalformedURLException e) {
            throw new DeployException("Failed to download container!", e);
        }

        /*
         * Rename the install directory to the container home directory so it
         * doesn't matter what the name is of the zip file and avoid case
View Full Code Here

                    final File destFile = new File("target/" + contextName + ".war");

                    try {
                        FileUtils.copyFile(srcFile, destFile);
                    } catch (final IOException e) {
                        throw new DeployException("Failed to copy WAR file: " + path, e);
                    }

                    path = destFile.getPath();
                }
            } else {
                deployableType = determineDeployableType(type);
            }

            /*
             * Add the deployable
             */
            addDeployable(configuration, path, deployableType);
        }

        // create installedLocalContainer
        installedLocalContainer = (InstalledLocalContainer) new DefaultContainerFactory().createContainer("glassfish2",
                ContainerType.INSTALLED, configuration);

        // configure installedLocalContainer
        installedLocalContainer.setHome(containerHome);
        final Logger fileLogger = new FileLogger(new File(cargoLogFilePath + "cargo.log"), true);
        fileLogger.setLevel(LogLevel.DEBUG);
        installedLocalContainer.setLogger(fileLogger);
        installedLocalContainer.setOutput(cargoLogFilePath + "output.log");

        // set the system properties
        installedLocalContainer.setSystemProperties(systemProperties);
        try {
            completeGlassfishConfiguration();
        } catch (final IOException e) {
            throw new DeployException("Failed to complete the Glassfish configuration while setting the env files", e);
        }

        if (LOGGER.isInfoEnabled()) {
            LOGGER.info("Starting Glassfish [" + configurationName + "]...");
        }
View Full Code Here

TOP

Related Classes of nl.tranquilizedquality.itest.cargo.exception.DeployException

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.