com.stevesouza.jamon.JamonHelloWorld Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of helloworld_unwoven_jamon Show documentation
Show all versions of helloworld_unwoven_jamon Show documentation
This pom simply has an unwoven HelloWorld class, that also registers jamon as jmx so users can see automon and jamon
integration. The resulting jar can be used to test AspectJ load time weaving.
package com.stevesouza.jamon;
import com.jamonapi.JamonPropertiesLoader;
import com.jamonapi.MonitorFactory;
import com.jamonapi.jmx.JmxUtils;
import com.stevesouza.helloworld.HelloWorld;
/**
* Created by stevesouza on 2/13/15.
*/
public class JamonHelloWorld extends HelloWorld {
public JamonHelloWorld() throws Exception {
/** Init jamon */
JamonPropertiesLoader loader = new JamonPropertiesLoader();
MonitorFactory.addListeners(loader.getListeners());
JmxUtils.registerMbeans();
}
public String hiSteve() {
return "hi steve";
}
public static void main(String[] args) throws Exception {
JamonHelloWorld helloWorld = new JamonHelloWorld();
System.out.println(helloWorld.hiSteve());
helloWorld.run(args);
System.out.println(MonitorFactory.getReport());
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy