SimpleServer

    The SimpleServer example object shows one of the ways that you can use the dynamicManagement package. It will instantiate any class with a null constructor and dynamically create a ModelMBean for it. Then it will register this MBean with a JMX agent running an HTTP adaptor. So you can now access all of this object's attributes and functions via web forms.

    java org.jmx4odp.dynamicManagent.SimpleServer (http adaptor port) (class name)

    There is a pair of start scripts in the jmx4odp/bin:

    UNIX: startSimpleServerExample.sh
    DOS: startSimpleServerExample

    These scripts will start a SimpleServer at whichever port you have defined as your HTTP adaptor in your jmx4odp/src/conf/basic_build.properties file. It will start the server with java.lang.Object as its sample class.

    If you have not altered the j4o_html_port setting in the properties file, then after running the startSimpleServer script, you should just be able to open a web browser to:
    http://localhost:7000

    This is your JMX agent, and you should see an MBean listed in the SimpleServer domain with the ObjectName "class=java.lang.Object." This is your Object class wrapped by your dynamically generated ModelMBean. By clicking on the link, you can access the Object and its attributes and functions.