Is there any way to run a Java program from inside another Java program without using Runtime exec?
Is there some kind of JavaExecutor tool which one could use with a DiagnosticCollector? (Like JavaCompiler)?
Call it through Reflection if you want to pass in class name during runtime. If program throws an exception, capture the stack trace and use it for further diagnostics.
Yes,IBM provides one Diagnostics Collector for gathering documentation and diagnostic data associated with Java Virtual Machine (JVM) problems. At JVM start up it runs a Diagnostic Configuration Check.
main()
method?Runtime.exec()
? Is the sub-program already compiled or do you only have the source? Do you want to run it in the same JVM or a child JVM?