}
@Test
public void testWithMonitoringViaInvocationProxy() throws Exception{
SimpleService unmonitoredInstance = new SimpleServiceImpl();
MoskitoInvokationProxy proxy = new MoskitoInvokationProxy(
unmonitoredInstance,
new ServiceStatsCallHandler(),
new ServiceStatsFactory(),
"SimpleService",
"service",
"test-sub-system",
SimpleService.class
);
SimpleService monitoredInstance = (SimpleService)proxy.createProxy();
for (int i=0; i<10; i++){
monitoredInstance.doSomethingMethod();
}