Hi Tobias!

Thanks for the tip!

We didn't make any explicit changes to the config regarding gzip-filter or 
cache-filter. I guess it is possible that 4.4.2 introduced these changes, 
although I am starting to think the problem may lie elsewhere.

I've done some more tests - 4.4.2 systems under windows don't exhibit the 
problem. Another difference is the Tomcat version - 6.0.32 in production, 
6.0.29 elsewhere.

I'll keep looking for the reason, but in the meantime I have found a workaround 
by converting the way the form works to use AJAX-submit directly to the 
paragraph, instead of a full page submit. In this way I avoid writing output 
before the execute() method of the paragraph is called, and everything works.

Thanks a lot for your help! I'm going to investigate the cache filter in 
production next.

Regards from Vienna,

Richard



Von: [email protected] [mailto:[email protected]] 
Im Auftrag von Tobias Mattsson
Gesendet: Mittwoch, 09. März 2011 13:10
An: Magnolia User-List
Betreff: Re: [magnolia-user] Session Behaviour different in 4.4.2?

Hi Richard,

What you're seeing is a paragraph that wants to create a session (setting a 
cookie header in the response) after the response has already be committed (has 
been written too). This happens because the template has written data to the 
response and then performed an include on the paragraph.

This is not an issue when you have either or both the cache filter and the gzip 
filter enabled since they buffer in memory everything that is to be written to 
the response. Hence adding the cookie header works.

Could it be that where you previously had either of them configured you now 
have neither?

// Tobias

On Mar 9, 2011, at 11:36 AM, Unger, Richard wrote:


Hi fellow Magnolians!

We've discovered a problem:  we have a form on our public site, which, when 
submitted, writes a value into the user session (   
MgnlContext.setAttribute("name","value", Context.SESSION_SCOPE);  ).
This is done in the model class for the paragraph.

under Magnolia 4.3.8, this worked fine
under Magnolia 4.4.2, it is no longer working, with the exception:

java.lang.IllegalStateException: Cannot create a session after the response has 
been committed


Has there been a change with regards to the session handling between 4.4.2 and 
4.3.8?

Any ideas?

Thanks!

Regards from Vienna,

Richard

________________________________
----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: 
<[email protected]<mailto:[email protected]>>
----------------------------------------------------------------


________________________________
----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: 
<[email protected]<mailto:[email protected]>>
----------------------------------------------------------------


----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------

Reply via email to