Couple changes:

1) Fix the event registration detection (string/array for args, not object/array)
2) Add a 30 second connection timeout for the client to successfully authorize before the server will close the connection.
This commit is contained in:
Ken Moore
2016-03-03 11:57:45 -05:00
parent 4fa264ea4f
commit 1fc3b3fbb4
4 changed files with 23 additions and 7 deletions

View File

@@ -14,7 +14,6 @@ EventWatcher::EventWatcher(){
//Only put non-thread-specific stuff here
starting = true;
oldhostname = sysadm::General::RunCommand("hostname").simplified();
}
EventWatcher::~EventWatcher(){
@@ -111,12 +110,14 @@ void EventWatcher::DispatchStarting(QString ID){
QJsonObject obj;
obj.insert("process_id", ID);
obj.insert("state", "running");
LogManager::log(LogManager::EV_DISPATCH, obj);
LogManager::log(LogManager::EV_DISPATCH, obj);
qDebug() << "Got Dispatch starting: sending event...";
emit NewEvent(DISPATCHER, obj);
}
void EventWatcher::DispatchFinished(QJsonObject obj){
LogManager::log(LogManager::EV_DISPATCH, obj);
qDebug() << "Got Dispatch Finished: sending event...";
emit NewEvent(DISPATCHER, obj);
}