Examples of fetchOutput()


Examples of com.sun.faban.common.CommandHandle.fetchOutput()

                // Run the command in the foreground
                CommandHandle ch = RunContext.exec(myServers[i], stopCmd);

                // Check if the server was even running before stop was issued
                // If not running, asadmin will print that on stdout
                byte[] output = ch.fetchOutput(Command.STDOUT);

                if (output != null) {
                    String outStr = new String(output);
                    if (outStr.indexOf("stopped.") != -1 ||
                            outStr.indexOf("isn't running.") != -1) {
View Full Code Here

Examples of com.sun.faban.common.CommandHandle.fetchOutput()

   */
    private static Integer checkServerStopped(String hostName)
            throws Exception {
        Command checkCmd = new Command(asadminCmd, "list-domains");
        CommandHandle handle = RunContext.exec(hostName, checkCmd);
        byte[] output = handle.fetchOutput(Command.STDOUT);
        if (output != null) {
            String outStr = new String(output);
            if (outStr.indexOf("domain1 not running") != -1)
                return 1;
            else
View Full Code Here

Examples of com.sun.faban.common.CommandHandle.fetchOutput()

                    // Run the command in the foreground
                    CommandHandle ch = RunContext.exec(myServers[i], stopCmd);
                    // Check if the server was running before stop was issued
                    // If not running, apachectl will print that on stdout
                    byte[] output = ch.fetchOutput(Command.STDOUT);

                    if (output != null)
                        if ((output.toString()).indexOf("not running") != -1) {
                           continue;
                        }
View Full Code Here

Examples of com.sun.faban.common.CommandHandle.fetchOutput()

    private static boolean checkServerStarted(String hostName) throws Exception {
        Command checkCmd = new Command(asadminCmd, "list-domains");
        // checkCmd.setLogLevel(Command.STDOUT, Level.FINE);
        // checkCmd.setLogLevel(Command.STDERR, Level.FINE);
        CommandHandle handle = exec(hostName, checkCmd);
        byte[] output = handle.fetchOutput(Command.STDOUT);
        if (output != null) {
            String outStr = new String(output);
        if (outStr.indexOf("domain1 running") != -1)
            return true;
        else
View Full Code Here

Examples of com.sun.faban.common.CommandHandle.fetchOutput()

                // Run the command in the foreground
                CommandHandle ch = exec(myServers[i], stopCmd);
               
                // Check if the server was even running before stop was issued
                // If not running, asadmin will print that on stdout
                byte[] output = ch.fetchOutput(Command.STDOUT);

                if (output != null) {
                    String outStr = new String(output);
                    if (outStr.indexOf("stopped.") != -1 ||
                            outStr.indexOf("isn't running.") != -1) {
View Full Code Here

Examples of com.sun.faban.common.CommandHandle.fetchOutput()

    private static Integer checkServerStopped(String hostName) throws Exception {
        Command checkCmd = new Command(asadminCmd, "list-domains");
        // checkCmd.setLogLevel(Command.STDOUT, Level.FINE);
        // checkCmd.setLogLevel(Command.STDERR, Level.FINE);
        CommandHandle handle = exec(hostName, checkCmd);
        byte[] output = handle.fetchOutput(Command.STDOUT);
        if (output != null) {
            String outStr = new String(output);
            if (outStr.indexOf("domain1 not running") != -1)
                return 1;
            else
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.