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


  • Subject: RE: Websphere: a resource hog?
  • From: "Joe Pluta" <joepluta@xxxxxxxxxxxxxxxxx>
  • Date: Thu, 24 May 2001 17:44:17 -0500
  • Importance: Normal

Remember, though, Nathan, that this is a pure read-and-display type of
application.  For that sort of application, you're probably just as well off
with an NT or Linux box and a big ol' IDE drive.  You might have a
background task like DataMirror pumping data off the AS/400 onto the PC, and
you have no issues about security or failover.

It's when we start adding real transaction processing that the numbers will
begin to change.  Once I start actually updating the database, the balance
of the processing will inexorably tip back towards the server.  Remember, at
this point the database server is simply reading data, while the servlet is
busy converting it first from EBCDIC to ASCII, then formatting it as HTML.
These are no mean feats.  Converting 4500 bytes of data from EBCDIC to
unicode is going to require quite a few milliseconds in and of itself, and
yet the whole operation takes less than 100 msec.

And I've run the pure Java numbers - they're roughly triple.

If what you are saying is that Java is slower than native RPG, then I think
we all agree.  However, the Java solution has benefits the RPG solution does
not, at least if the Java is designed correctly.  What's going to be
interesting over the next month or so is to see how many ways I am able to
leverage what I've written.  For example, I can use these same classes to
output XML.  Have you added that capability to your classes yet?

And remember - I can always offload the servlet processing to another
platform.  That's simply impossible with RPG.

Joe

P.S. Here's the doGet method for the servlet that outputs a source file in
an HTML table (with alternating colored rows and columns):
-------------------------
PrintWriter             out;

int rows = 50;
boolean queued = true;

String title = "Source Lister - Listing " + rows + " rows.";

// Get data from server and convert to taggable data
Object[][] data = new PbdBmk01(getSession(request, queued)).get(rows);
TaggableTable table = ObjectDataTable.getTable(data);

// Create tag structure for alternating rows and columns
AbstractRowTag[] rowTags =
{
        new HtmlIndexedRowTag(" style=background:#c0c0ff",
                new AbstractCellTag[] {
                        new HtmlSimpleCellTag(""),
                        new HtmlSimpleCellTag(" style=background:#a0a0ff"),
                }
        ),
        new HtmlIndexedRowTag("",
                new AbstractCellTag[] {
                        new HtmlSimpleCellTag(""),
                        new HtmlSimpleCellTag(" style=background:#d0d0d0"),
                }
        ),
};

// Create table tag and use it to convert data to HTML
AbstractTableTag tag = new HtmlIndexedTableTag(" border=0 cellspacing=0",
rowTags);
StringBuffer html = tag.getTag(table);

// set content type and other response header fields first
response.setContentType("text/html");

// then write the data of the response
out = response.getWriter();

out.println("<HTML>");
out.println("<HEAD>");
out.println("<TITLE>" + title + "</TITLE>");
out.println("<meta http-equiv=\"Expires\" content=\" \">");  // reload
out.println("</HEAD>");

out.println("<BODY>");

out.println("<H1>" + title + "</H1>");

out.println("<P>Listing the source.");
out.println("<P>");

out.println(html);

out.println("</BODY>");
out.println("</HTML>");
out.close();
-------------------------

As you can see, the colors are dynamic, the table parameters are dynamic,
the number of rows and columns are dynamic, and so on.  This is just a very
basic table; my classes allow tons of flexibility.

You may have noticed the class PbdBmk01: that's the server proxy for the RPG
server... the RPG code is about 100 lines long.


> -----Original Message-----
> From: owner-midrange-l@midrange.com
> [mailto:owner-midrange-l@midrange.com]On Behalf Of Nathan M. Andelin
> Sent: Thursday, May 24, 2001 4:39 PM
> To: MIDRANGE-L@midrange.com
> Subject: RE: Websphere: a resource hog?
>
>
> Joe, I couldn't help but notice how little CPU your RPG database
> I/O server
> is consuming.  Some people think I'm Whacko to say that a Web interface
> might be 30 times more expensive than 5250.  But these figures tend to
> confirm it.  After all, what would the CPU numbers be if this were a 100%
> Java solution?
>
> On the other hand, I fully agree with your point that the new 270
> models are
> more than capable of serving Websphere applications.
>
>
> Nathan.

+---
| This is the Midrange System Mailing List!
| To submit a new message, send your mail to MIDRANGE-L@midrange.com.
| To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com.
| To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.