Mustang agents can be used to probe running NB instances for data

Just thinking about how to extract useful information from a running NB platform instance. Not so hard to do using Mustang, it seems. You can use an API (supported in the Sun JDK at least) to connect to VMs running NB on the same machine and run some code in that VM, which can with a little work make use of NB APIs: project ZIP The API: com.sun.tools.attach A little annoying to develop such an agent incrementally because you can't reload the same agent classes in a given target VM, and Mustang seems to also reject attempts to call loadAgent twice with the same JAR. A workaround is to rename both the agent JAR and agent main class each time you test it. Probably this could be automated somehow, or you could have a "stub" agent which you never change, which just loads a named JAR in a fresh class loader and runs it. Next stop: figuring out how to use this as a stepping-stone to set up a regular JMX client connection. The rub is that jconsole has a nice UI to let you pick a VM to attach to from among locally running VMs, but then shows a generic JMX browser. I want to write a domain-specific JMX GUI client that (in the spirit of requiring zero configuration) will by default display all VMs running on the local machine matching some pattern. The goal is a general-purpose NB runtime inspector: #69773
Comments:

Post a Comment:
  • HTML Syntax: NOT allowed
About

jglick

Search

Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today