K
Kai Schlamp
Hello.
I am looking for a good way to list operating system processes from
within a Java application. There is a lot of information on the web
already. But most come up with running an external program, like "ps"
or "tasklist", and parsing the result.
Is there a Java library available that helps doing this in a system
independent way (no matter how it does it in the background)?
Another option, when one is only interested in Java processes, is to
use the LocalVirtualMachine class of jconsole.jar. The problem is that
it depends on tools.jar, which is quite large (12 MB), and I don't
like the idea to ship my product with such a huge dependent library,
just for fetching a list of running processes.
An ideas?
Regards,
Kai
I am looking for a good way to list operating system processes from
within a Java application. There is a lot of information on the web
already. But most come up with running an external program, like "ps"
or "tasklist", and parsing the result.
Is there a Java library available that helps doing this in a system
independent way (no matter how it does it in the background)?
Another option, when one is only interested in Java processes, is to
use the LocalVirtualMachine class of jconsole.jar. The problem is that
it depends on tools.jar, which is quite large (12 MB), and I don't
like the idea to ship my product with such a huge dependent library,
just for fetching a list of running processes.
An ideas?
Regards,
Kai