
April 17th, 2003, 08:43 AM
|
|
Junior Member
|
|
Join Date: Apr 2003
Posts: 1
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
IllegalStateException on response.getOutputStream()
I am using a JSP, which is used for html presentation & a servlet is called from this JSP, which invokes a response.getOutputStream() & this results in IllegalStateException being thrown. According to servlets specifications, servlet can support either of the JspWriter or OutputStream object. So it is illegal to call getOutputStream() method on the response object as 'out' object is already present in any JSP (internally there must be a call like response.getWriter() to fetch this 'out;' object).
Any solution for this? I want to use OutputStream object somehow or the other in a JSP.
I am using JRun4 app server. It follows the servlet specs strictly. However i have found some low end app servers like Resin, which do not follo servlet sepcifications strictly, being able to handle this senario. But I need to use JRun4. No other option.
Any solution anybody?
Jaideep
|