File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes Illegal State exception Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Illegal State exception" Watch "Illegal State exception" New topic

Illegal State exception

Nila dhan
Ranch Hand

Joined: Sep 15, 2005
Posts: 161
Hi pals,
I call a Transport.send(msg)(which is in another java file) in an action and after that forward the response using mapping.findForward() to another page.At this point i at times get cannot forward after response has been committed exception.Will increasing the buffer size solve this problem or is there any other way to solve this?
[ October 17, 2005: Message edited by: Nila dhan ]
dema rogatkin
Ranch Hand

Joined: Oct 09, 2002
Posts: 294
Unless you use Transfer-Encoding=chunked, you can't do that.

Edit: If you forward inside the same app, then I think you can try dispatcher.forward() to avoid the problem.
[ October 17, 2005: Message edited by: dema rogatkin ]

Tough in space?, <a href="" target="_blank" rel="nofollow">Get J2EE servlet container under 150Kbytes here</a><br />Love your iPod and want it anywhere?<a href="" target="_blank" rel="nofollow">Check it here.</a><br /><a href="" target="_blank" rel="nofollow">Curious about generic in Java?</a><br /><a href="" target="_blank" rel="nofollow">Hate ant? Use bee.</a><br /><a href="" target="_blank" rel="nofollow">Need contacts anywhere?</a><br /><a href="" target="_blank" rel="nofollow">How to promote your business with a search engine</a>
I agree. Here's the link:
subject: Illegal State exception
It's not a secret anymore!