openejb-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From joe <fischauto...@yahoo.de>
Subject Re: testing for running OpenEJB server
Date Thu, 24 Feb 2011 15:38:27 GMT
> ********************************************************************************
> public void runningVMs() throws MonitorException, URISyntaxException {
> MonitoredHost monitoredHost = MonitoredHost.getMonitoredHost("localhost");
>        Set<Integer>  activeVms = monitoredHost.activeVms();
>        for (int psId : activeVms)
>        {
>           MonitoredVm monitoredVm = monitoredHost.getMonitoredVm(new
> VmIdentifier(String.valueOf(psId)));
>           String mainClass = MonitoredVmUtil.mainClass(monitoredVm, false);
>           System.out.println(mainClass + " [" + psId + "]");
>        }
> }

interesting, output here is:

Program [5540] <--- OpenEJB
  [3056]
  [4240]
App [4220]
NetworkServerControl [2720]

currently i stay with my java socket approach, but this is something 
good to know, thx

Mime
View raw message