This API call provides an indication of the status of ExtraView. It is often used on a server remote to the ExtraView installation and called every few minutes to check that the ExtraView server is functioning correctly. If the call does not get a valid return, an alarm or notification may then be sent to an administrator.
Input
Class |
Name |
Type |
Required |
Details |
GetHeartbeatRequest |
userId |
String |
Yes |
The callers user name |
GetHeartbeatRequest |
password |
String |
Yes |
The callers password |
Output
Class |
Name |
Type |
Required |
Details |
GetHeartbeatResponse |
success |
boolean |
Yes |
True is succeeded False if failed |
GetHeartbeatResponse |
returnCode |
String |
No |
See Appendix for details |
GetHeartbeatResponse |
returnMessage |
String |
No |
Human readable message |
GetHeartbeatResponse |
evStatus |
String |
Yes |
ExtraView System Status |
GetHeartbeatResponse |
dbStatus |
String |
Yes |
ExtraView Database Status |
GetHeartbeatResponse |
dbDate |
Date |
Yes |
The current date in the Database |
GetHeartbeatResponse |
freeMemory |
String |
Yes |
Free memory on application server |
GetHeartbeatResponse |
totalMemory |
Integer |
Yes |
Total memory on application server |
GetHeartbeatResponse |
serviceCount |
Integer |
Yes |
The current number of Extraview sessions |
GetHeartbeatResponse |
executeTime |
Long |
Yes |
The time it took to execute this call |
GetHeartbeatResponse |
tasks |
Array of TaskInfo |
No |
The information on tasks configured on the node of the server where the service is executed |
TaskInfo |
nodeId |
String |
No |
The name of the node hosting the service |
TaskInfo |
startOption |
String |
No |
|
TaskInfo |
taskState |
String |
No |
START_NOW, STOP_NOW, START_ON_BOOT, or none |
TaskInfo |
pollInterval |
String |
No |
The minimum number of seconds between polled executions |
TaskInfo |
threads |
Array of ThreadInfo |
No |
|
ThreadInfo |
threadState |
String |
No |
Running or stopped |
ThreadInfo |
secsSinceExecution |
Long |
No |
The number of seconds since the task was most recently scheduled to run |
ThreadInfo |
priority |
Long |
No |
The priority of the thread (using Java thread priority values). This may not appear in the output |
Example
public static void testGetHeartbeat(EVSystemServiceStub stub) {
try {
GetHeartbeatDocument reqEnvelope = GetHeartbeatDocument.Factory.newInstance();
GetHeartbeatRequest request = reqEnvelope.addNewGetHeartbeat().addNewParam0();
request.setUserId(ServiceClientHelper.ADMIN_USER_ID);
request.setPassword(ServiceClientHelper.ADMIN_PASSWORD);
GetHeartbeatResponseDocument resEnvelope = stub.getHeartbeat(reqEnvelope);
GetHeartbeatResponse response = resEnvelope.getGetHeartbeatResponse().getReturn();
if (response.getSuccess()) {
System.out.println("success: [" + response.getReturnCode() + "] : " +
response.getReturnMessage());
} else {
System.out.println("failure: [" + response.getReturnCode() + "] : " +
response.getReturnMessage());
}
} catch (Exception e) {
e.printStackTrace();
System.err.println("nnn");
}
}