Well, presently i am working on a small project and i come across strange problem..
I am working on WDSC for iseries Version 5.1 on development side and IBM WebSphere Application Server - Express, 5.0.1 as production server;
I am actually looking over the spooled files at the Printer Device , virtually using com.ibm.as400.vaccess.*; and javax.swing.JFrame
It is working very fine on the development server; but !!! it gives problem on the production server; !!! I guess it has got all to do with hierarchy of classLoader loading classes and different versions of IBM toolBox for java;
Works as required on development server; I have jt400.jar in WEB-INF/lib for this project (maybe the development server first looks for classes in WEB-INF/lib)
On the Production Server, the problem comes at
(1) String printerName=usr.getPrintDevice(); IT returns a null value; whats the problem here??? development server did not do this.. Hmm.. I guess the IBM toolbox for java on Production server is different??? it loads classes from somewhere else first before it looks for classes from WEB-INF/lib for the particular class
ok, I commented this line, to see where it goes by giving the actual Printer Device; // String printerName=usr.getPrintDevice(); String printerName="PrinterName";
(2) Again at VPrinter vp=new VPrinter(pri); it gives a Problem??? it says [Servlet Error]-[com/ibm/as400/vaccess/VPrinter]: java.lang.NoClassDefFoundError: What is really happening??? I have no clue... I did not have any problem in my previous project(s), NO difference between development & Production servers before.. though i did not use the vaccess classes & User class before..
BUT what is happening now??? I know there will be some people who know what is going on, so please help me solve this problem; Your help is greatly appreciated... Thanks again :-)
Joined: Jun 15, 2002
I have also looked at the LOG file on the production server, and i have something like this :
which shows that there is a NullPointerException happening at the Printer class, which belongs to IBM toolbox for java. why did not this happen in the development server??? So it definitely means that the Printer class is different in development server from the production server???