final StandardHost standardHost = (StandardHost) source;
final String type = event.getType();
if (Lifecycle.PERIODIC_EVENT.equals(type)) {
contextListener.checkHost(standardHost);
} else if (Lifecycle.AFTER_START_EVENT.equals(type) && REMOTE_SUPPORT) {
final TomEERemoteWebapp child = new TomEERemoteWebapp();
if (!hasChild(standardHost, child.getName())) {
standardHost.addChild(child);
} // else old tomee webapp surely
}
} else if (StandardServer.class.isInstance(source)) {
final StandardServer standardServer = (StandardServer) source;