[jboss-user] [Tomcat, HTTPD, Servlets & JSP] - Re: Cookies lost when included JSP file used

Raist_Majere do-not-reply at jboss.com
Sat Oct 6 00:47:31 EDT 2007


You should use a page directive specifying a greater buffer size. Take a look at the spec:
anonymous wrote : 
  | buffer
  | Specifies the buffering model for the initial out JspWriter to
  | handle content output from the page.
  | If none, then there is no buffering and all output is written
  | directly through to the ServletResponse PrintWriter.
  | The size can only be specified in kilobytes. The suffix kb is
  | mandatory or a translation error must occur.
  | If a buffer size is specified then output is buffered with a
  | buffer size not less than that specified.
  | Depending upon the value of the autoFlush attribute, the
  | contents of this buffer is either automatically flushed, or an
  | exception is raised, when overflow would occur.
  | The default is buffered with an implementation buffer size of
  | not less than 8kb.
  | 
  | autoFlush
  | Specifies whether the buffered output should be flushed
  | automatically (true value) when the buffer is filled, or
  | whether an exception should be raised (false value) to
  | indicate buffer overflow. It is illegal, resulting in a translation
  | error, to set autoFlush to false when buffer=none. The default
  | value is true
  | 

addCookie sets a header, which cannot be done once the page is flushed.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4092240#4092240

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4092240



More information about the jboss-user mailing list