agave-monitors/monitors-core/src/main/java/org/iplantc/service/monitor/managers/MonitorManager.java
/**
	 * Sends off all the monitors for a particular event and UUID for processing.
	 * 
	 * @param monitor the monitor to check
	 * @param createdBy the user who initiated the check
	 * @return a monitor with the check results or null if the system is not available to check
	 */
Sends off all the monitors for a particular event and UUID for processing.

@param monitor the monitor to check
@param createdBy the user who initiated the check
@return a monitor with the check results or null if the system is not available to check
Sends off all the monitors for a particular event and UUID for processing . @param monitor the monitor to check @param createdBy the user who initiated the check @return a monitor with the check results or null if the system is not available to check
public MonitorCheck check(Monitor monitor, String createdBy)
	{
		RemoteSystem system = null;
		MonitorCheck check = null;
		try {
			system = getSystem(monitor);
			check = doStorageCheck(monitor, createdBy);
			if (monitor.getSystem() instanceof ExecutionSystem) {
				MonitorCheck loginCheck = doLoginCheck(monitor, createdBy);
				if (check.getResult() != MonitorStatusType.FAILED) {
					check = loginCheck;
				}
			}
			if (check.getResult().equals(MonitorStatusType.PASSED)) {
				monitor.setLastSuccess(new Date(check.getCreated().getTime()));
				try {
					getMonitorDao().persist(monitor);
				} catch (Throwable e) {
					log.error("Check for monitor " + monitor.getUuid() +
							" succeeded, but failed to updated the monitor's last success date.");
				}
			}
		} catch (SystemUnknownException | SystemUnavailableException e) {
			disableMonitor(monitor);
			log.debug("Disabled monitor " + monitor.getUuid() + " on system " +
					monitor.getSystem().getSystemId() + " due to system being inactive.");
		}
		return check;
	}
public MonitorCheck check ( Monitor monitor , String createdBy ) { RemoteSystem system = null ; MonitorCheck check = null ; try { system = getSystem ( monitor ) ; check = doStorageCheck ( monitor , createdBy ) ; if ( monitor . getSystem ( ) instanceof ExecutionSystem ) { MonitorCheck loginCheck = doLoginCheck ( monitor , createdBy ) ; if ( check . getResult ( ) != MonitorStatusType . FAILED ) { check = loginCheck ; } } if ( check . getResult ( ) . equals ( MonitorStatusType . PASSED ) ) { monitor . setLastSuccess ( new Date ( check . getCreated ( ) . getTime ( ) ) ) ; try { getMonitorDao ( ) . persist ( monitor ) ; } catch ( Throwable e ) { log . error ( "Check for monitor " + monitor . getUuid ( ) + " succeeded, but failed to updated the monitor's last success date." ) ; } } } catch ( SystemUnknownException | SystemUnavailableException e ) { disableMonitor ( monitor ) ; log . debug ( "Disabled monitor " + monitor . getUuid ( ) + " on system " + monitor . getSystem ( ) . getSystemId ( ) + " due to system being inactive." ) ; } return check ; }
Sends off all the monitors for a particular event and UUID for processing.
Sends off all the monitors for a particular event and UUID for processing .