× 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.



Ahh....your requirements make that third option a bit difficult.  I
personally don't know of a way to call into Java from COBOL or CL directly
unless you use JNI, but I'm pretty sure that requires a JVM on the system
you would be running your COBOL or CL program on.  In a perfect world, a
JVM on the source system would make this task much simpler.
Given your situation, perhaps you could try using dataqueues.  We do this
now for having a Java process on one system called from any iSeries
programs that can access dataqueues.
The way we do it is that we have two dataqueues set up on the system that
needs to talk to Java.  One dataqueue is a regular sequential data queue
that we use to write a delimited command string into, and the other
dataqueue is a keyed dataqueue that allows us to write back a response to a
specific key that wouldn't collide with other processes trying to access
the Java.  The Java process uses the iSeries Toolkit to wait on the
dataqueue for commands.  Once it receives and entry, the Java process does
it's work, and then writes back a response to the keyed dataqueue that the
source program is waiting on.  The reponse is also a delimited string.
Maybe this process would work for you.
----------------------------------------------------------------------
Chris DeLashmutt
Senior R&D Analyst
LeasePlan USA
1165 Sanctuary Pkwy., Alpharetta, GA  30004
Phone: 678-202-8695
Fax: 678-566-8551
----------------------------------------------------------------------



                                                                                
                                                          
                      Mike Burdette                                             
                                                          
                      <Mike.Burdette@comp        To:       
java400-l@xxxxxxxxxxxx                                                         
                      orium.com>                 cc:                            
                                                          
                      Sent by:                   Subject:  Re: Calling a Java 
PGM on another iSeries...                                   
                      java400-l-bounces@m                                       
                                                          
                      idrange.com                                               
                                                          
                                                                                
                                                          
                                                                                
                                                          
                      10/13/2003 04:06 PM                                       
                                                          
                      Please respond to                                         
                                                          
                      Java Programming on                                       
                                                          
                      and around the                                            
                                                          
                      iSeries / AS400                                           
                                                          
                                                                                
                                                          
                                                                                
                                                          




Hi Chris:

Thanks for your reply to my question.

Two details I left out of my original question:
1.) Java is not installed on the source system
2.) I do need a certain level of interaction between the source program,
and the program on the remote machine. (A couple of String parms for the a
status and reason code should suffice).

Given these constraints, would the third option you suggested be the best:

"Another option, if you want to call specific methods on the Java class on
the remote system, would be to use something like RMI or EJBs to handle
the
request on the remote system, and then they could actually return Java
Objects to your source system."

(RMI is my only option, since we will be moving to WAS Express very soon,
with no EJB support)

We are a COBOL shop; would anyone have any examples of RMI calls from
COBOL or CL?

Thanks





As an Amazon Associate we earn from qualifying purchases.

This thread ...


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.