× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Bradley V. Stone wrote:
So, looking for ideas on handling this. In a nutshell, you have a
standalone app that uses Java inside of RPG and you want to ensure the
classpath is set properly when your application runs, no matter what else
they are running or if the JVM is already running for that job.

Brad:

FWIW, I'm not a big fan of invoking Java directly from RPG. I know it can be done but, for the same reasons you mention, I don't think it's a great idea.

Personally I would suggest you start the java process up in a daemon job and communicate to it with data queues. Simply have the java process monitor a queue for commands and have your RPG send the command requests through the queue.

That way you only have the JVM startup penalty once ... and the job is running in batch. Your RPG program suffers no performance impact because the data queue api is relatively light weight.

Obviously all ther java code would have to be in your daemon job's classpath.

JMO, obviously.... but I've been using this kind of technique for quite a while with great success (using sockets though, not data queues ... given a chance to rework the implementation, I would probably use a data queue).

david


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.