Package org.hpccsystems.ws.client
Class HPCCWsTopologyClient
- java.lang.Object
-
- java.util.Observable
-
- org.hpccsystems.ws.client.utils.DataSingleton
-
- org.hpccsystems.ws.client.BaseHPCCWsClient
-
- org.hpccsystems.ws.client.HPCCWsTopologyClient
-
public class HPCCWsTopologyClient extends BaseHPCCWsClient
Facilitates accessing HPCC Systems instance topology information. This client can be used for fetching topology information regarding the target HPCCSystem of special interest are the cluster groups, and the target clusters within those groups.
-
-
Field Summary
Fields Modifier and Type Field Description static String
WSTOPOLOGYWSDLURI
ConstantWSTOPOLOGYWSDLURI="/WsTopology"
-
Fields inherited from class org.hpccsystems.ws.client.BaseHPCCWsClient
DEAFULTECLWATCHPORT, DEFAULTECLWATCHTLSPORT, initErrMessage, stub, targetESPInterfaceVer, targetHPCCBuildVersion, verbose, wsconn
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
HPCCWsTopologyClient(Connection baseConnection)
Instantiates a new HPCC ws topology client.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static HPCCWsTopologyClient
get(String protocol, String targetHost, String targetPort, String user, String pass)
Gets the.static HPCCWsTopologyClient
get(String protocol, String targetHost, String targetPort, String user, String pass, int timeout)
Gets the.static HPCCWsTopologyClient
get(Connection connection)
Gets the.org.hpccsystems.ws.client.wrappers.gen.wstopology.TpClusterInfoResponseWrapper
getClusterInfo(String clusterName)
Gets the cluster info.org.apache.axis2.client.Stub
getDefaultStub()
Gets the default stub.List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpLogicalClusterWrapper>
getLogicalClusters()
Gets the logical clusters.org.hpccsystems.ws.client.wrappers.gen.wstopology.TpServicesWrapper
getServices()
Gets the services.String
getServiceURI()
Gets the service URI.static int
getServiceWSDLPort()
Gets the service WSDL port.static String
getServiceWSDLURL()
Gets the service WSDLURL.String[]
getValidClusterNames(String clusterGroupType)
Gets the valid cluster names.List<String>
getValidTargetClusterNames()
Get the names of all available target clusters (mythor, myroxie, etc.) from all cluster groups (hthor, thor, roxie, etc)String[]
getValidTargetClusterNames(String clusterGroupType)
Get the names of all available target clusters from a given cluster group (hthor, thor, roxie, Hole, etc).String[]
getValidTargetClusterNamesArray()
Get the names of all available target clusters (mythor, myroxie, etc.) from all cluster groups (hthor, thor, roxie, etc)String[]
getValidTargetGroupNames()
Get names of all available target clusters on the given HPCC System.List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpTargetClusterWrapper>
getValidTargetGroups()
Get full descriptions of all valid cluster groups on the target HPCC System.boolean
ping()
Ping.boolean
printValidTargetClusters(PrintStream stream)
prints available target cluster names to given print stream.org.hpccsystems.ws.client.wrappers.gen.wstopology.TpDropZoneWrapper
queryDropzone(String name)
Query dropzone.List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpMachineWrapper>
queryDropzoneMachines(String name)
Query dropzone machines.List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpDropZoneWrapper>
queryDropzones(String namefilter)
Query dropzones.-
Methods inherited from class org.hpccsystems.ws.client.BaseHPCCWsClient
compatibilityCheck, compatibilityCheck, equals, fastRefresh, fullRefresh, getConnectionURL, getInitError, getServiceVersion, getServiceVersion, getServiceWSDLPort, getServiceWSDLURL, getStubConnectionTO, getTargetESPInterfaceVersion, getVerbose, handleECLExceptions, handleECLExceptions, handleEspExceptions, handleEspExceptions, handleEspSoapFaults, handleEspSoapFaults, hashCode, hasInitError, isComplete, loadESPRuntimeInterfaceVer, setActiveConnectionInfo, setClientAuth, setStubConnectionTO, setStubOptions, setVerbose, verifyStub
-
Methods inherited from class org.hpccsystems.ws.client.utils.DataSingleton
monitor
-
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
-
-
-
-
Field Detail
-
WSTOPOLOGYWSDLURI
public static final String WSTOPOLOGYWSDLURI
ConstantWSTOPOLOGYWSDLURI="/WsTopology"
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
HPCCWsTopologyClient
protected HPCCWsTopologyClient(Connection baseConnection)
Instantiates a new HPCC ws topology client.- Parameters:
baseConnection
- the base connection
-
-
Method Detail
-
getServiceURI
public String getServiceURI()
Gets the service URI.- Specified by:
getServiceURI
in classBaseHPCCWsClient
- Returns:
- the service URI
-
getServiceWSDLURL
public static String getServiceWSDLURL()
Gets the service WSDLURL.- Returns:
- the service WSDLURL
-
getServiceWSDLPort
public static int getServiceWSDLPort()
Gets the service WSDL port.- Returns:
- the service WSDL port
-
get
public static HPCCWsTopologyClient get(Connection connection)
Gets the.- Parameters:
connection
- the connection- Returns:
- the HPCC ws topology client
-
get
public static HPCCWsTopologyClient get(String protocol, String targetHost, String targetPort, String user, String pass)
Gets the.- Parameters:
protocol
- the protocoltargetHost
- the target hosttargetPort
- the target portuser
- the userpass
- the pass- Returns:
- the HPCC ws topology client
-
get
public static HPCCWsTopologyClient get(String protocol, String targetHost, String targetPort, String user, String pass, int timeout)
Gets the.- Parameters:
protocol
- the protocoltargetHost
- the target hosttargetPort
- the target portuser
- the userpass
- the passtimeout
- the timeout- Returns:
- the HPCC ws topology client
-
printValidTargetClusters
public boolean printValidTargetClusters(PrintStream stream) throws Exception, ArrayOfEspExceptionWrapper
prints available target cluster names to given print stream.- Parameters:
stream
- - Stream to print onto (System.out | System.err)- Returns:
- - Boolean, success
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getValidTargetGroups
public List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpTargetClusterWrapper> getValidTargetGroups() throws Exception, ArrayOfEspExceptionWrapper
Get full descriptions of all valid cluster groups on the target HPCC System.- Returns:
- the valid target groups
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getValidTargetGroupNames
public String[] getValidTargetGroupNames() throws Exception, ArrayOfEspExceptionWrapper
Get names of all available target clusters on the given HPCC System.- Returns:
- the valid target group names
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
queryDropzone
public org.hpccsystems.ws.client.wrappers.gen.wstopology.TpDropZoneWrapper queryDropzone(String name) throws Exception, ArrayOfEspExceptionWrapper
Query dropzone.- Parameters:
name
- - The target dropzone name- Returns:
- the tp drop zone wrapper
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
queryDropzones
public List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpDropZoneWrapper> queryDropzones(String namefilter) throws Exception, ArrayOfEspExceptionWrapper
Query dropzones.- Parameters:
namefilter
- - Empty for all dropzones, or specific dropzeon name- Returns:
- the list
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
queryDropzoneMachines
public List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpMachineWrapper> queryDropzoneMachines(String name) throws Exception, ArrayOfEspExceptionWrapper
Query dropzone machines.- Parameters:
name
- the name- Returns:
- the list
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getValidClusterNames
public String[] getValidClusterNames(String clusterGroupType) throws Exception
Gets the valid cluster names.- Parameters:
clusterGroupType
- the cluster group type- Returns:
- the valid cluster names
- Throws:
Exception
- the exception
-
getValidTargetClusterNames
public String[] getValidTargetClusterNames(String clusterGroupType) throws Exception, ArrayOfEspExceptionWrapper
Get the names of all available target clusters from a given cluster group (hthor, thor, roxie, Hole, etc).- Parameters:
clusterGroupType
- -- RoxieCluster, HoleCluster- Returns:
- the valid target cluster names
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getValidTargetClusterNamesArray
public String[] getValidTargetClusterNamesArray() throws Exception, ArrayOfEspExceptionWrapper
Get the names of all available target clusters (mythor, myroxie, etc.) from all cluster groups (hthor, thor, roxie, etc)- Returns:
- the valid target cluster names array
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getValidTargetClusterNames
public List<String> getValidTargetClusterNames() throws Exception, ArrayOfEspExceptionWrapper
Get the names of all available target clusters (mythor, myroxie, etc.) from all cluster groups (hthor, thor, roxie, etc)- Returns:
- the valid target cluster names
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getServices
public org.hpccsystems.ws.client.wrappers.gen.wstopology.TpServicesWrapper getServices() throws Exception, ArrayOfEspExceptionWrapper
Gets the services.- Returns:
- the services
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getClusterInfo
public org.hpccsystems.ws.client.wrappers.gen.wstopology.TpClusterInfoResponseWrapper getClusterInfo(String clusterName) throws Exception, ArrayOfEspExceptionWrapper
Gets the cluster info.- Parameters:
clusterName
- the cluster name- Returns:
- the cluster info
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
getLogicalClusters
public List<org.hpccsystems.ws.client.wrappers.gen.wstopology.TpLogicalClusterWrapper> getLogicalClusters() throws Exception, ArrayOfEspExceptionWrapper
Gets the logical clusters.- Returns:
- the logical clusters
- Throws:
Exception
- the exceptionArrayOfEspExceptionWrapper
- the array of esp exception wrapper
-
ping
public boolean ping() throws Exception
Ping.- Returns:
- true, if successful
- Throws:
Exception
- the exception
-
getDefaultStub
public org.apache.axis2.client.Stub getDefaultStub() throws org.apache.axis2.AxisFault
Gets the default stub.- Specified by:
getDefaultStub
in classBaseHPCCWsClient
- Returns:
- the default stub
- Throws:
org.apache.axis2.AxisFault
- the axis fault
-
-