Package org.jmanage.core.config.event

Examples of org.jmanage.core.config.event.ApplicationEvent


            return;
        }
        // Note that application removed event is not being handled. We probably don't care about
        //   the downtime of a removed application.
       
        ApplicationEvent appEvent = (ApplicationEvent)event;
        ApplicationDowntimeHistory downtimeHistory = getDowntimeHistory(appEvent.getApplicationConfig());
        assert downtimeHistory != null;
        if(appEvent instanceof ApplicationUpEvent){
            // application must have went down earlier
            assert downtimeHistory.getDowntimeBegin() != null;
            // log the downtime to the db
            recordDowntime(appEvent.getApplicationConfig().getApplicationId(),
                    downtimeHistory.getDowntimeBegin(), appEvent.getTime());
            downtimeHistory.applicationCameUp(appEvent.getTime());
        }else if(event instanceof ApplicationDownEvent){
            downtimeHistory.applicationWentDown(appEvent.getTime());
        }
    }
View Full Code Here

TOP

Related Classes of org.jmanage.core.config.event.ApplicationEvent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.