GemFire 5.7.1

com.gemstone.gemfire.admin
Class GemFireClientAdminTool

java.lang.Object
  extended by java.lang.Thread
      extended by com.gemstone.gemfire.admin.GemFireClientAdminTool
All Implemented Interfaces:
Runnable

public class GemFireClientAdminTool
extends Thread


Nested Class Summary
static class GemFireClientAdminTool.AdminConnection
           
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
static String CMD_STATUS_ABORTED
           
static String CMD_STATUS_DONE
           
static String CMD_STATUS_INIT
           
static String CMD_STATUS_RECEIVING
           
static String CMD_STATUS_SENDING
           
static String CMD_STATUS_SENT
           
static String CONX_STATUS_CONNECTED
           
static String CONX_STATUS_DISCONNECTED
           
static String TYPE_CLIENT
           
static String TYPE_SERVER
           
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
GemFireClientAdminTool()
           
 
Method Summary
 void addConnection(GemFireClientAdminTool.AdminConnection connection)
           
 void addConnection(String name, String type, String host, int port)
           
 void addMonitorEventListener(MonitorEventListener listener)
           
 void connectAll()
           
 void disconnectAll()
           
 void dispatchCommand(String cmd)
          For remote commands only.
 GemFireClientAdminTool.AdminConnection[] getAllAdminConnections()
           
 GemFireClientAdminTool.AdminConnection getConnection(String name)
           
static LogWriter getLogger()
           
 void init(String[] args)
           
 boolean isInteractive()
           
 void loadConfig(AdminConfig.Entry[] entries)
           
 void loadConfig(List l)
           
static void main(String[] argv)
           
static List parseArgs(String args)
          Move to server?
static String parseConfigLine(String configLine)
           
 void processCommand(String p_cmd)
           
 List readConfig(String fileLocation)
          Config must be of the format: Line1: Name= Line2: Type= Line3: Host= Line4: Port= TODO: Refactor, should not be returning instance variable . . .
 void removeConnection(GemFireClientAdminTool.AdminConnection connection)
           
 void removeConnection(String name)
           
 void removeMonitorEventListener(MonitorEventListener listener)
           
static String replaceForLineFeed(String str)
           
 void run()
           
 void setInteractive(boolean interactive)
           
 void showDownConnections()
           
 void showLastResults()
           
static String showMenu()
           
 void showTypedConxStatus(String type)
           
 void stopAllConnections()
           
 void stopProcessing()
           
static void usage()
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_SERVER

public static String TYPE_SERVER

TYPE_CLIENT

public static String TYPE_CLIENT

CMD_STATUS_INIT

public static String CMD_STATUS_INIT

CMD_STATUS_SENDING

public static String CMD_STATUS_SENDING

CMD_STATUS_SENT

public static String CMD_STATUS_SENT

CMD_STATUS_RECEIVING

public static String CMD_STATUS_RECEIVING

CMD_STATUS_DONE

public static String CMD_STATUS_DONE

CMD_STATUS_ABORTED

public static String CMD_STATUS_ABORTED

CONX_STATUS_CONNECTED

public static String CONX_STATUS_CONNECTED

CONX_STATUS_DISCONNECTED

public static String CONX_STATUS_DISCONNECTED
Constructor Detail

GemFireClientAdminTool

public GemFireClientAdminTool()
Method Detail

main

public static void main(String[] argv)

readConfig

public List readConfig(String fileLocation)
Config must be of the format:

  • Line1: Name=
  • Line2: Type=
  • Line3: Host=
  • Line4: Port= TODO: Refactor, should not be returning instance variable . . .

    Parameters:
    fileLocation -
    Returns:
    a list of config parameters

  • parseConfigLine

    public static String parseConfigLine(String configLine)

    loadConfig

    public void loadConfig(List l)
                    throws Exception
    Throws:
    Exception

    usage

    public static void usage()

    connectAll

    public void connectAll()

    disconnectAll

    public void disconnectAll()

    init

    public void init(String[] args)

    showTypedConxStatus

    public void showTypedConxStatus(String type)

    showDownConnections

    public void showDownConnections()

    processCommand

    public void processCommand(String p_cmd)

    parseArgs

    public static List parseArgs(String args)
    Move to server?

    Parameters:
    args -
    Returns:
    a list of arguments

    run

    public void run()
    Specified by:
    run in interface Runnable
    Overrides:
    run in class Thread

    addConnection

    public void addConnection(String name,
                              String type,
                              String host,
                              int port)

    addConnection

    public void addConnection(GemFireClientAdminTool.AdminConnection connection)

    removeConnection

    public void removeConnection(String name)

    removeConnection

    public void removeConnection(GemFireClientAdminTool.AdminConnection connection)

    getConnection

    public GemFireClientAdminTool.AdminConnection getConnection(String name)

    getLogger

    public static LogWriter getLogger()

    stopProcessing

    public void stopProcessing()

    stopAllConnections

    public void stopAllConnections()

    replaceForLineFeed

    public static String replaceForLineFeed(String str)

    showLastResults

    public void showLastResults()

    dispatchCommand

    public void dispatchCommand(String cmd)
    For remote commands only. Iterate over open connections and send the command to each one.

    Parameters:
    cmd -

    showMenu

    public static String showMenu()

    addMonitorEventListener

    public void addMonitorEventListener(MonitorEventListener listener)

    removeMonitorEventListener

    public void removeMonitorEventListener(MonitorEventListener listener)

    setInteractive

    public void setInteractive(boolean interactive)

    isInteractive

    public boolean isInteractive()

    loadConfig

    public void loadConfig(AdminConfig.Entry[] entries)

    getAllAdminConnections

    public GemFireClientAdminTool.AdminConnection[] getAllAdminConnections()

    GemFire 5.7.1

    Copyright © 2002-2008 GemStone Systems, Inc. All Rights Reserved.