Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
    Bookmark Topic Watch Topic
  • New Topic

Confused-Is clearing or flushing buffer same as committing of response  RSS feed

Maya Dolas
Posts: 26
  • Mark post as helpful
  • send pies
  • Report post to moderator

I am confused with the terminologies

"flushing of buffer" and "committing the response".

Are they same, if not could some one throw more light what happens in each case.

I was confused due to the jsp include and forward actions. Now in the include action if the flush attribute is set to true, the buffer is flushed prior to the inclusion. Now what does this flushing exactly mean - does it mean mere clearing of the buffer or sending the buffered contents to client (in other words start the committing of response). If its not committing of response, consider the foll ex

Now the contents of other.jsp

Now in this case will the contents of the including file before the include action sent to the client or they would be just ignored? If they are ignored it would result in a wrong HTML structure.

Now in jsp forward action, the buffered contents of the forwarding component are always ignored/cleared before the request processing is delegated to the forwarded component. Now in this case if buffer clearing is committing of response, then we should get IllegalStateException everytime, isn't it?

Also one more doubt, does the buffer and autoFlush attributes of page directive play some role in above cases.

Christophe Verré
Posts: 14691
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please do not duplicate threads. Continue the discussion there.
Don't get me started about those stupid light bulbs.
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!