com.wily.introscope.client.alerts.manager
Class IntroscopeClient

java.lang.Object
  extended by com.wily.introscope.client.alerts.manager.IntroscopeClient
All Implemented Interfaces:
IIntroscopeClient

public class IntroscopeClient
extends java.lang.Object
implements IIntroscopeClient

This is an implementation of the IIntroscopeClient interface. It represents a connection to a given Introscope Enterprise Manager. It provides the following functionalities: -Information on the configuration of the Introscope Enterprise Manager. -Parameters -Topics that the connection to the EM wants to subscribe to on the Subscription Web services provided by the Introscope Enterprise Manager. The available topics for the connection are: AgentInManModInventoryUpdate ManModInventoryUpdate AlertDefnInManModInventoryUpdate ManModStatusUpdate AgentStausUpdate AlertDefnInManModStatusUpdate AlertMessagesTriggered -Access to all the Polling Web Services that are available on the Introscope Enterprise Manager.


Field Summary
 
Fields inherited from interface com.wily.introscope.client.alerts.interfaces.IIntroscopeClient
CONTEXTPATH__ISCOPE_ALERT_POLLINGWS, CONTEXTPATH__ISCOPE_CONSUMER_REGISTRATION_POLLINGWS, CONTEXTPATH__ISCOPE_DASHBOARD_URL, CONTEXTPATH__ISCOPE_EMLIFECYCLE_POLLINGWS, CONTEXTPATH__ISCOPE_EVENTS_POLLINGWS, CONTEXTPATH__ISCOPE_METRICS_DATA_POLLINGWS, CONTEXTPATH__ISCOPE_METRICS_LIST_POLLINGWS
 
Constructor Summary
IntroscopeClient(java.lang.String iscopeWebServiceHost, int iscopeWebServicePort, java.lang.String iscopeUser, java.lang.String iscopePassword, IIntroscopeTopic[] topicsToSubscribeTo)
          Constructor for constructing a connection to the Introscope Enterprise Manager providing the input parameters below.
 
Method Summary
 boolean equals(java.lang.Object inObj)
          Two IntroscopeClient objects are equal if the iscope web service host and port are the same.
 IAlertPollingService getAlertPollingWS()
          Obtains the Alerts Polling Web Service
 IConsumerRegistrationService getConsumerRegistrationService()
          Obtains the Events Data Web Service
 DEMConfig getEmConfig()
          Obtains the DEMConfig which comprises of the current Host, IP and launch time for the Introscope Enterprise Manager.
 java.lang.String getEmDashboardURL()
          Obtains the Enterprise Manager Dashboard URL
 IEmLifecycleService getEMLifecycleWS()
          Obtains the EM Lifecycle Polling Web Service
 java.lang.String getIscopePassword()
          Obtains the password for the userid that is used to login to the Introscope Enterprise Manager.
 java.lang.String getIscopeUser()
          Obtains the userid that is used to login to the Introscope Enterprise Manager.
 java.lang.String getIscopeWebServiceHost()
          Obtains the host where the Introscope Web Services will be available.
 int getIscopeWebServicePort()
          Obtains the port where the Introscope Web Services will be available.
 IMetricsDataService getMetricDataWS()
          Obtains the Metrics Data Web Service
 IMetricsListService getMetricListWS()
          Obtains the Metrics List Web Service
 IIntroscopeTopic[] getTopicsToSubscribeTo()
          Obtains the list of topics that the client needs to subscribe to
 int hashCode()
           
 void setEmConfig(DEMConfig emConfig)
          Set the current DEMConfig for the Introscope Enterprise Manager.
 java.lang.String toString()
          Converts the Host and port to a string
 void validate()
          Checks if the EM pointed to by this IIntroscopeClient 1.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IntroscopeClient

public IntroscopeClient(java.lang.String iscopeWebServiceHost,
                        int iscopeWebServicePort,
                        java.lang.String iscopeUser,
                        java.lang.String iscopePassword,
                        IIntroscopeTopic[] topicsToSubscribeTo)
                 throws java.lang.Exception
Constructor for constructing a connection to the Introscope Enterprise Manager providing the input parameters below. The SDK user has the choice of subscribing to specific Topics that are published by the EM and not all.

Parameters:
iscopeWebServiceHost -
iscopeWebServicePort -
iscopeUser -
iscopePassword -
topicsToSubscribeTo -
Throws:
java.lang.Exception
Method Detail

validate

public void validate()
              throws java.net.MalformedURLException,
                     WebServicesNotInstalledException,
                     java.net.UnknownHostException,
                     UserNotAuthorizedException,
                     java.net.ConnectException
Checks if the EM pointed to by this IIntroscopeClient 1. Is running 2. Can be connected to using the credentials given 3. Has the required web services installed

Specified by:
validate in interface IIntroscopeClient
Throws:
java.net.MalformedURLException
WebServicesNotInstalledException
java.net.UnknownHostException
UserNotAuthorizedException
java.net.ConnectException

getIscopeWebServiceHost

public java.lang.String getIscopeWebServiceHost()
Obtains the host where the Introscope Web Services will be available.

Specified by:
getIscopeWebServiceHost in interface IIntroscopeClient
Returns:
String

getIscopeWebServicePort

public int getIscopeWebServicePort()
Obtains the port where the Introscope Web Services will be available.

Specified by:
getIscopeWebServicePort in interface IIntroscopeClient
Returns:
int

getIscopePassword

public java.lang.String getIscopePassword()
Obtains the password for the userid that is used to login to the Introscope Enterprise Manager.

Specified by:
getIscopePassword in interface IIntroscopeClient
Returns:
String

getIscopeUser

public java.lang.String getIscopeUser()
Obtains the userid that is used to login to the Introscope Enterprise Manager.

Specified by:
getIscopeUser in interface IIntroscopeClient
Returns:
String

getTopicsToSubscribeTo

public IIntroscopeTopic[] getTopicsToSubscribeTo()
Obtains the list of topics that the client needs to subscribe to

Specified by:
getTopicsToSubscribeTo in interface IIntroscopeClient
Returns:
IIntroscopeTopic[]

getEMLifecycleWS

public IEmLifecycleService getEMLifecycleWS()
                                     throws java.lang.Exception
Obtains the EM Lifecycle Polling Web Service

Specified by:
getEMLifecycleWS in interface IIntroscopeClient
Returns:
IEmLifecycleService
Throws:
java.lang.Exception

getAlertPollingWS

public IAlertPollingService getAlertPollingWS()
                                       throws java.lang.Exception
Obtains the Alerts Polling Web Service

Specified by:
getAlertPollingWS in interface IIntroscopeClient
Returns:
IAlertPollingService
Throws:
java.lang.Exception

getMetricDataWS

public IMetricsDataService getMetricDataWS()
                                    throws java.lang.Exception
Obtains the Metrics Data Web Service

Specified by:
getMetricDataWS in interface IIntroscopeClient
Returns:
IMetricsDataService
Throws:
java.lang.Exception

getMetricListWS

public IMetricsListService getMetricListWS()
                                    throws java.lang.Exception
Obtains the Metrics List Web Service

Specified by:
getMetricListWS in interface IIntroscopeClient
Returns:
IMetricsListService
Throws:
java.lang.Exception

getConsumerRegistrationService

public IConsumerRegistrationService getConsumerRegistrationService()
                                                            throws java.lang.Exception
Obtains the Events Data Web Service

Specified by:
getConsumerRegistrationService in interface IIntroscopeClient
Returns:
IEventsDataService public IEventsDataService getEventsDatsWS() throws Exception { if (eventsDataService == null) { EventsDataService_ServiceLocator locator = new EventsDataService_ServiceLocator(); eventsDataService = locator.getEventsDataService(new URL(getIscopeEventsPollingWSURL())); ((org.apache.axis.client.Stub) eventsDataService).setUsername(iscopeUser); ((org.apache.axis.client.Stub) eventsDataService).setPassword(iscopePassword); } return eventsDataService; } /** Obtains the Consumer Registration Service
Throws:
java.lang.Exception

setEmConfig

public void setEmConfig(DEMConfig emConfig)
Set the current DEMConfig for the Introscope Enterprise Manager. This method is peridically invoked by the EM Hearbeat lifecycle listener, on receipt of a EM start/stop/heartbeat message from the Enterprise manager.

Specified by:
setEmConfig in interface IIntroscopeClient
Parameters:
emConfig -

getEmConfig

public DEMConfig getEmConfig()
                      throws java.lang.Exception
Obtains the DEMConfig which comprises of the current Host, IP and launch time for the Introscope Enterprise Manager.

Specified by:
getEmConfig in interface IIntroscopeClient
Returns:
DEMConfig
Throws:
java.lang.Exception

toString

public java.lang.String toString()
Converts the Host and port to a string

Overrides:
toString in class java.lang.Object
Returns:
String

getEmDashboardURL

public java.lang.String getEmDashboardURL()
                                   throws java.lang.Exception
Obtains the Enterprise Manager Dashboard URL

Specified by:
getEmDashboardURL in interface IIntroscopeClient
Returns:
String
Throws:
java.lang.Exception

equals

public boolean equals(java.lang.Object inObj)
Two IntroscopeClient objects are equal if the iscope web service host and port are the same.

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object


Copyright © 2007 CA Inc. All Rights Reserved.