File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes BEA/Weblogic and the fly likes JSP page displays junk when data to be displayed is more Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "JSP page displays junk when data to be displayed is more" Watch "JSP page displays junk when data to be displayed is more" New topic
Author

JSP page displays junk when data to be displayed is more

Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Hello Experts,

I have a simple JSP page which works fine when the number of records to be displayed are less. When the number of records increases a limit then this JSP page displays junk characters. Something like below:

í˜QoÛ8Çß ä;°: O'+Iï°Mbk‘K4‡¤ Ú¤·÷t %ÚbC‰Z’¶ãÅ~øJ²-ÙN·M{‡ôð·‹þ8œÎ0Œ/Þ\ŸÝþûæœe.Wìæî—g,£è_¯Î¢èÍíöËÛÛ«KvÐßg·†V:© ®¢èü]Ð 2çÊã(šÏçýù«¾6“èö}ôàuøÉM3t­™ýÔ¥AÜëí}æÛTæ<䪰Ëպ+^L†(Hï <{Œ>ƒaÈÞÞÞސõ, ã½Þ Ž3¯0¿Nålœñ$á™.œÑ¤-¡†(Ü0(th6"ˆü´–¦ýÇ4Ý>ÉyWEⵯUÜ1£!˼\Æs™ ¹~X°ÂÌ„yLýùC)°-ýû•âNÕHx»(Ek‚.òQ;aIƍn8uãðuGOÁs1 øÔeÚ´æ^ž(ÁÎtžO ™p


Below is the JSP code:



It would be great is someone can help me with this issue. I tried increasing the buffer but didnt get any help.

Regards
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

Works fine for me.

Why are you doing this with obsolete scriptlets rather than with the JSTL and EL?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Bear Bibeault wrote:Works fine for me.

Why are you doing this with obsolete scriptlets rather than with the JSTL and EL?


Thanks for testing at your end. Please try again by increasing the max limit of i to 2000 in the while loop.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

I increased it to 10,000, then 100,000, then 1,000,000. It works fine.

Why are you doing this with obsolete scriptlets rather than with the JSTL and EL?
Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Bear Bibeault wrote:I increased it to 10,000, then 100,000, then 1,000,000. It works fine.

Why are you doing this with obsolete scriptlets rather than with the JSTL and EL?


I have some legacy code that is written using scriplets. We are finding this issue with using JSTL also.

Thanks for testing this. I am using weblogic server and able to repeatedly reproduce this issue with 2000. What app server you used while you run this and what was the version of JSP?

Regards
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

Tomcat 6.0.30
JVM 1.6.0_51-b11-457-11M4509

Browsers: Safari, Chrome, Firefox, Opera, SeaMonkey.

All worked fine (though Opera was slow as molasses).
Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Bear Bibeault wrote:Tomcat 6.0.30
JVM 1.6.0_51-b11-457-11M4509

Browsers: Safari, Chrome, Firefox, Opera, SeaMonkey.

All worked fine (though Opera was slow as molasses).


Appreciate your quick response. But I am getting this issue repeatedly on weblogic server. I dont have tomcat to test this. Any pointers how to debug this further to reach the root cause?

Thanks in advance for your help.

Regards
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

It would likely take less than 10 minutes to set up a Tomcat server to test. If it acts the same, then you know it's something in your web app; if not, time to get help from WebLogic.
Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Bear Bibeault wrote:It would likely take less than 10 minutes to set up a Tomcat server to test. If it acts the same, then you know it's something in your web app; if not, time to get help from WebLogic.


Sure . I am on the way to setup tomcat.. :)
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

Another thing to check is to create a new, bare-bones (use all defaults) web app that just contains the JSP and deploy it to WebLogic. That'll determine whether settings in the problem app are affecting the page or not.
Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Bear Bibeault wrote:Another thing to check is to create a new, bare-bones (use all defaults) web app that just contains the JSP and deploy it to WebLogic. That'll determine whether settings in the problem app are affecting the page or not.


Thanks !!! I tested in Tomcat and it works like a charm!!! Now will test in weblogic by creating a simple JSP deployment.. a minimal one...

Will post the result soon... Thanks You!!
Nikh Sadd
Greenhorn

Joined: May 05, 2012
Posts: 9
Nikh Sadd wrote:
Bear Bibeault wrote:Another thing to check is to create a new, bare-bones (use all defaults) web app that just contains the JSP and deploy it to WebLogic. That'll determine whether settings in the problem app are affecting the page or not.


Thanks !!! I tested in Tomcat and it works like a charm!!! Now will test in weblogic by creating a simple JSP deployment.. a minimal one...

Will post the result soon... Thanks You!!


And it works fine as a standalone JSP .. so some problme with my application which use tag libs...
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60781
    
  65

And only in Weblogic, eh?

I've moved this to the WebLogic forum so that the savvy can maybe help you along.

Is what you have posted the whole page as it exists in the misbehaving application? If not, try that page exactly as you posted it.
German Gonzalez-Morris
Ranch Hand

Joined: Nov 16, 2009
Posts: 157

Which WLS version ?


http://devwebcl.blogspot.com/
German Gonzalez-Morris
Ranch Hand

Joined: Nov 16, 2009
Posts: 157

Ok. it works fine in WLS 10.3.6:


HEllo how do you do? ok fine bye HEllo how do you do? ok fine bye HEllo how do you do? ok fine bye HEllo how do you do? ok fine bye HEllo how do you do? ok fine bye HEllo how do you do? ok fine bye HEllo how do you...


So, I think you already solved it...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JSP page displays junk when data to be displayed is more
 
Similar Threads
Not able to set attribute in JSP
JSP Not able to Identify the JS, CSS file path
Charset problem in JOptionPane on Applet
include file Directive not working properly. Variable not resolved in jsp
using 4 includes only shows bgcolor of first