@Test public void testMonitoring() throws Exception { final BootUtil bootUtil = new BootUtil(); final Map<String, Object> platformProperties = bootUtil.getContext().getProperties(); platformProperties.put(HttpServerSilverService.HTTP_SERVER_PORT, 18080); final Thread platform = bootUtil.getMicroservicePlatform(this.getClass().getPackage().getName(), HttpServerMicroserviceProvider.class.getPackage().getName()); platform.start(); while (monitoringSilverService == null) { monitoringSilverService = (MonitoringSilverService) bootUtil.getContext().getProvider(MonitoringSilverService.class); Thread.sleep(200); } Assert.assertTrue(Utils.waitForHttp("http: platformProperties.get(HttpServerSilverService.HTTP_SERVER_PORT) + "/" + platformProperties.get(MonitoringSilverService.MONITORING_URL) + "/", 200)); platform.interrupt(); platform.join(); }
@Override public Context getContext() { return context; }
MonitoringMicroserviceProvider implements MicroserviceProvider, MonitoringSilverService { @Override public Context getContext() { return context; } }
MonitoringMicroserviceProvider implements MicroserviceProvider, MonitoringSilverService { @Override public Context getContext() { return context; }  }
MonitoringMicroserviceProvider implements MicroserviceProvider, MonitoringSilverService { @Override public Context getContext() { return context; }  @Override void initialize(final Context context); @Override Context getContext(); @Override void run(); }
MonitoringMicroserviceProvider implements MicroserviceProvider, MonitoringSilverService { @Override public Context getContext() { return context; }  @Override void initialize(final Context context); @Override Context getContext(); @Override void run();  }