Nagios XI : last signature time is undefinedDescriptionNagios connector update undefined value for all parameters of an event when Nagios event list size is 1. Nagios version: 5.7.2Steps to Reproduce 1. Open the https://<instance-name>.service.com/em_connector_instance_list.do 2. Open the Connector record for the Nagios 3. Activate the Nagios connector 4. If Nagios connector pulls the event and event list size is 1, all parameters value of the event will be undefined. WorkaroundPLease update getEventsFromJSON and execute functions with following code in the connector script: 1. getEventsFromJSON: function(parsed) { if (parsed == null) return null; var events = []; if (parsed.recordcount === 0) return events; ms.log("getEventsFromJSON record count was greater than 0 count is " + parsed.recordcount); var entryData = ""; var timeOfEvent = ""; var node = ""; var severity = ""; var severityType = ""; var type = ""; var event = null; var mappedSeverity = ""; if(parsed.recordcount == 1){ timeOfEvent = parsed.stateentry[0].state_time; timeOfEvent = this.translateToGMT(timeOfEvent); type = parsed.stateentry[0].service_description; entryData = parsed.stateentry[0].output; node = parsed.stateentry[0].host_name; severity = parsed.stateentry[0].state; severityType = parsed.stateentry[0].state_type; mappedSeverity = this.getMappedSeverity(severity, severityType); event = this.getPopulatedEvent(type, timeOfEvent, mappedSeverity, entryData, node); events[0] = event; return events; } var i = 0; for (; i < parsed.recordcount; i++) { node = parsed.stateentry[i].host_name; timeOfEvent = parsed.stateentry[i].state_time; ms.log("DEBUG 44 ******* state_time parsed:" + parsed.stateentry[i].state_time); timeOfEvent = this.translateToGMT(timeOfEvent); type = parsed.stateentry[i].service_description; entryData = parsed.stateentry[i].output; severity = parsed.stateentry[i].state; severityType = parsed.stateentry[i].state_type; mappedSeverity = this.getMappedSeverity(severity, severityType); event = this.getPopulatedEvent(type, timeOfEvent, mappedSeverity, entryData, node); events[i] = event; } return events; }, 2. execute: function() { ms.log("NagiosJS Connector: execute connection ..."); var retVal = {}; try { var utcDate = ""; var url = this.getNagiosURL(); var response = this.getResponseFromURL(url); if(response == null){ this.addError("Failed to connect to Nagios on execute. Response is null"); retVal['status'] = FAILURE.toString(); retVal['error_message'] = errorMessage; return retVal; } var resultJson = this.getJSONFromResponse(response); if (resultJson == null) { retVal['status'] = FAILURE.toString(); retVal['error_message'] = errorMessage; return retVal; } var events = null; var uxDate = null; var lastSig=this.probe.getParameter("last_event"); if(resultJson.recordcount == 0){ ms.log("execute method: no records found. count was " + resultJson.recordcount + " records"); retVal['status'] = SUCCESS.toString(); return retVal; } else if(resultJson.stateentry[0].state_time==lastSig && resultJson.recordcount == 1){ ms.log("execute method: no new records found."); retVal['status'] = SUCCESS.toString(); return retVal; } else if(resultJson.recordcount == 1){ ms.log("execute method: first entry time "+resultJson.stateentry[0].state_time); } else{ ms.log("execute method: recordcount > 0 response first entry time "+resultJson.stateentry[0].state_time); } events = this.getEventsFromJSON(resultJson); if (events == null) { retVal['status'] = FAILURE.toString(); this.addError("execute method: events array is null"); retVal['error_message'] = errorMessage; return retVal; } ms.log("execute events.length " + events.length); var sender = SNEventSenderProvider.getEventSender(); var i = 0; var successFlag = true; for (; i< events.length; i++) { if (events[i] && !this.filterEvent(lastSig, events[i])) { successFlag = successFlag && sender.sendEvent(events[i]); } } if (successFlag) { retVal['status'] = SUCCESS.toString(); if (events.length > 0) { var lastEventSignature = events[0].getTimeOfEvent(); retVal['last_event'] = lastEventSignature; } } else { retVal['status'] = FAILURE.toString(); this.addError("Execute method: Failed to send events"); retVal['error_message'] = errorMessage; } } catch (e) { this.addError("Failed to retreive Nagios events"); this.addError(e); retVal['status'] = FAILURE.toString(); retVal['error_message'] = errorMessage; } ms.log("NagiosJS Connector: execute finished " + retVal['status']); return retVal; }, Related Problem: PRB1436505