Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

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

 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hello,

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.

Thanks
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Please do not duplicate threads. Continue the discussion there.
 
Could you hold this kitten for a sec? I need to adjust this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
    Bookmark Topic Watch Topic
  • New Topic