Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Executing a JAVA API from an RPGLE program

90 views
Skip to first unread message

Drew Stephens

unread,
Nov 11, 2009, 5:26:25 PM11/11/09
to
I am trying to incorporate a java based API to process credit card
transactions directly from a traditional green screen application.

I have the API but am new to JAVA and ILE procedures. Does anyone
have a simple example of prototyping, creating and using RPG Procedure
to execute JAVA?

any help will be appreciated.

Tim M

unread,
Nov 11, 2009, 11:49:46 PM11/11/09
to
I strongly encourage you to not even attempt to invoke the JVM from RPG.
While it is possible to do such a thing, it will be a complete hog on
your system if you have multiple interactive jobs creating multiple JVMs
and each of those trying to communicate with the authorizer.

Instead you should have a single job running a Java program that
contains your Java API. one thread of execution in this JVM should be
coded to wait on requests from on a data queue waiting for requests
from your green screen RPG app. As the java processes each data queue
request, it responds on a keyed data queue that the requesting RPG
application is waiting on. The response data queue would be keyed, most
likely, by device/job name.

Note that as demand increases you can start multiple threads working the
request data queue.


dieter...@t-online.de

unread,
Nov 12, 2009, 1:49:03 AM11/12/09
to
I have published Appserver4RPG for this stuff. It works similar to the
approach, Tim recommended. You can get it at www.bender-dv or at
Sourceforge. If you have further questions, feel free to contact me
directly.

Dieter Bender

Drew Stephens

unread,
Nov 12, 2009, 9:11:07 AM11/12/09
to

That is exactly what we are going to do. I am just having trouble
writing the program that runs within the service job.

Drew Stephens

unread,
Nov 12, 2009, 9:11:25 AM11/12/09
to
On Nov 12, 1:49 am, dieter.ben...@t-online.de wrote:
> I have published Appserver4RPG for this stuff. It works similar to the
> approach, Tim recommended. You can get it atwww.bender-dvor at

Thanks. I will look at it.

Kaj Julius

unread,
Nov 15, 2009, 1:53:32 PM11/15/09
to

<dieter...@t-online.de> skrev i en meddelelse
news:hdgb4v$mnf$03$1...@news.t-online.com...

>I have published Appserver4RPG for this stuff. It works similar to the
> approach, Tim recommended. You can get it at www.bender-dv or at
> Sourceforge. If you have further questions, feel free to contact me
> directly.
>
> Dieter Bender

I think the correct URL is www.bender-dv.de (a German website).


John Yeung

unread,
Dec 3, 2009, 1:43:30 AM12/3/09
to
On Nov 15, 1:53 pm, "Kaj Julius" <j...@ldp.com.dk> wrote:
> <dieter.ben...@t-online.de> skrev i en meddelelsenews:hdgb4v$mnf$03$1...@news.t-online.com...

>
> >I have published Appserver4RPG for this stuff. It works similar to the
> > approach, Tim recommended. You can get it atwww.bender-dvor at

> > Sourceforge. If you have further questions, feel free to contact me
> > directly.
>
> > Dieter Bender
>
> I think the correct URL iswww.bender-dv.de(a German website).

That doesn't seem to work either, at least as of this writing.
Googling for Appserver4RPG brings up this SourceForge site:

http://sourceforge.net/projects/appserver4rpg/

John

dieter...@t-online.de

unread,
Dec 3, 2009, 3:13:11 AM12/3/09
to
... sorry Guys, http://www.bender-dv.de should work, you would just have to
follow the link to AppServer4RPG on the left hand side. But the mentioned
SourceForge Site keeps the same stuff.
My Homepage has some more OpenSource components (mainly RPG), but is written
in german language.

Dieter

0 new messages