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



David,

What other options do you have for inter process communication on the
AS/400? In ILE C you can use shared memory, is that available in RPG?

Do you think that shared memory might be faster, all that you then send
through the data queues are enough information to identify the shared memory
that must be accessed by the receiving application.

Can the AS/400 Toolbox people please comment on the speed of accessing data
queues from java using the toolbox classes.

Etienne

-----Original Message-----
From: David Morris [mailto:David.Morris@plumcreek.com]
Sent: Tuesday, January 22, 2002 2:54 PM
To: java400-l@midrange.com
Subject: RE: keep a java program open


Etienne,

Since you mention scalability, I assume you want speed. Data queues
in the past with Java were terribly slow. I know there was a fix made
that
eliminated an unnecessary delay. Data queues are also inefficient with

varying length data.

I hit that delay problem in an application that passed quite a bit of
data.
I converted that code to use a user space to pass the bulk of data and

a single message on a data queue to trigger an action and it was many
times faster.

You are right that data queues allow you to scale your application. I
built a server framework that uses a configurable number of server
jobs and it has worked out very well. It was written in RPGIV, but I am

sure that the performance benefit is the same. We use it mostly to
farm out FTP jobs, but it also comes in handy for processors we use
to sync-up our data warehouse files.

David Morris

>>> Etienne.Richards@penske.com 01/22/02 12:16PM >>>

I have looked at the CPU usage of the java application that is waiting
for a
message on the queue and it looked good (It seemed like it blocked
while
waiting, it was not doing polling). Data queues also seemed like the
fasted
way to get messages to move between different applications that run on
the
same AS/400 machine.

I also feel that this type of solution would scale very well. You can
have
multiple java programs or multiple java threads read from the same
queue and
only one of them will get a message, that way you can pre-start more
jobs or
threads to do the work.

For me it felt as if the communication between to two jobs (CL and
Java
process) was almost instantaneous. It also allowed me to make use of
connection pooling for jdbc and AS400 connections which reduced the
time to
complete the request even more.

Are there any other ways to move data from java back to a calling RPG /
CL
program? I know you can use PCML to call a RPG program from java and
you can
have input and output parameters but what can you do if you want to
call a
java program from RPG while wanting to have input and output
parameters? You
could probably use data areas, MQ Series, Data queues but they all seem
to
fall into the same type of solution.

I hope I answered your question, I know I started rambling a bit...

Etienne
_______________________________________________
This is the Java Programming on and around the iSeries / AS400 (JAVA400-L)
mailing list
To post a message email: JAVA400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/java400-l
or email: JAVA400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.


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.