For information on how to set up a node and server, please refer to the JPPF documentation.
Once you have installed a server and node, perform the following steps:
- open a command prompt in JPPF-x.y-samples-pack/CustomMBeans
- build the sample: type "ant jar"; this will create a file named CustomMBeans.jar
- copy CustomMBeans.jar in the "lib" folder of the JPPF driver installation, to add it to the driver's classpath. This is enough, as the node will download the custom MBean code from the server.
- start the driver and node
- in the sample's command prompt, type "ant run" to run the sample
- you should see the following display:
[echo] Testing the custom server MBean [java] The server has 8 available processors [echo] Testing the custom node MBean [java] The node has 8 available processors
For a detailed explanation, please refer to the related documentation in the Pluggable MBeans section.
If you need more insight into the code of this demo, you can consult the Java source files located in the CustomMBeans/src folder.
In addition, There are 2 privileged places you can go to: