×
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.
I am trying to get some numbers on the speed of various parts of the
"java->as/400 interaction" stuff we are building.
Right now I am looking at the ProgramCall while calling the API I
believe should be the quickest to actually do serverside (converting the
*CURRENT date to *DTS format) and I have found that the native approach
is the SLOWEST. Is this right? Host is V5R3.
PC->AS/400
==========
stay on thread = false
is thread safe = true
0.9956 ms/call
AS/400->AS/400 not native
=======================
stay on thread = false
is thread safe = true
1.2036 ms/call
AS/400->AS/400 native jt400 on system
=================================
stay on thread = true
is thread safe = true
2.3937 ms/call
The code in question looks like (not runnable):
=================
AS400 as400 = new AS400();
as400.connectService(AS400.COMMAND);
String program = "QWCCVTDT.PGM";
AS400DataType[] signature = { new AS400Text(10), new
AS400Text(1), new AS400Text(10), new AS400Text(8), new AS400Text(100) };
AS400Function f = new AS400Function(as400, program, signature);
ProgramCall programCall = f.getProgramCall();
programCall.setThreadSafe(true);
System.out.println(as400);
System.out.println("stay on thread = " +
programCall.isStayOnThread());
System.out.println("is thread safe = " +
programCall.isThreadSafe());
int count = 10000;
long start = System.currentTimeMillis();
for (int j = 0; j < count; j++) {
String[] result = f.call(new String[] { "*CURRENT", "",
"*DTS" });
}
System.out.println((System.currentTimeMillis() - start) * 1.0 /
count + " ms/call");
=================
I'd like to hear opinions and experiences :)
As an Amazon Associate we earn from qualifying purchases.
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.