1 |
|
//---PACKAGE DECLARATION--- |
2 |
+ |
package uk.ac.ukc.iscream.filter; |
3 |
|
|
4 |
|
//---IMPORTS--- |
5 |
|
import uk.ac.ukc.iscream.core.*; |
99 |
|
_socketOut.println("OK"); |
100 |
|
_socketOut.flush(); |
101 |
|
} |
102 |
+ |
|
103 |
+ |
String date = new Long(System.currentTimeMillis()).toString(); |
104 |
+ |
String hostname = _socket.getInetAddress().getHostName(); |
105 |
+ |
String ipadd = _socket.getInetAddress().getHostAddress(); |
106 |
+ |
String xml = "<packet type=\"heartbeat\" machine_name=\""+hostname+"\" date=\""+date+"\" ip=\""+ipadd+"\"></packet>"; |
107 |
+ |
|
108 |
+ |
FilterThread t = new FilterThread(xml, _parent, _logRef); |
109 |
+ |
t.start(); |
110 |
|
|
111 |
|
} catch (Exception e) { |
112 |
|
_logRef.write(toString(), Logger.ERROR, "ERROR: " + e.getMessage()); |