cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Lenyon" <m...@lenyon.com>
Subject Re: problems tracking session from page to page
Date Tue, 27 May 2003 12:56:25 GMT
hi geoff,

yes, i've tried putting create-session in the xsp:page tag.  but i still get
the IllegalStateException.  as you're probably aware, having create-session
causes the following line to appear at the beginning of the generate()
method:

Session session = request.getSession(true);

that's the line that the exception refers to.

here's a snippet from my sitemap to exemplify one of the two pages where to
problem occurs:

            <map:match pattern="choose_item.html">
                <map:aggregate element="page">
                    <map:part src="cocoon:/choose_item.products"/>
                    <map:part src="cocoon:/general.productcategories"/>
                    <map:part src="cocoon:/common"/>
                    <map:part src="cocoon:/general.currentproduct"/> <!--
only page that accesses session -->
                </map:aggregate>
                <map:transform type="xslt" src="style/choose_item.xsl"/>
                <map:transform type="i18n"/>
                <map:serialize type="html"/>
            </map:match>

does that provide any useful clues?

thanks in advance.

Mike Lenyon
----- Original Message -----
From: "Geoff Howard" <cocoon@leverageweb.com>
To: <cocoon-users@xml.apache.org>
Sent: Tuesday, May 27, 2003 8:22 AM
Subject: Re: problems tracking session from page to page


> But I think the problem is that your code is working with the
> session after processing starts and attempting there to create
> a session after it's too late.  Have you tried the create-session
> attribute yet?
>
> Geoff Howard
>
> At 07:05 AM 5/27/2003, you wrote:
> >antonio,
> >
> >thanks for your response, but please look at what i'm saying:
> >
> ><xsp:page
> >     language="java"
> >     xmlns:xsp="http://apache.org/xsp"
> >     xmlns:xsp-request="http://apache.org/xsp/request/2.0"
> >     xmlns:xsp-session="http://apache.org/xsp/session/2.0">
> >
> >causes the error message:
> >java.lang.IllegalStateException: Cannot create a session after the
response
> >has been committed
> >
> >in other words, not having create-session="true" doesn't matter.  simply
> >having
> >     xmlns:xsp-session="http://apache.org/xsp/session/2.0" causes the
> >problem.
> >
> >Mike Lenyon
> >----- Original Message -----
> >From: "Antonio Gallardo" <agallardo@agsoftware.dnsalias.com>
> >To: <cocoon-users@xml.apache.org>
> >Sent: Tuesday, May 27, 2003 1:49 AM
> >Subject: Re: problems tracking session from page to page
> >
> >
> > > Hi:
> > >
> > > I dont remember if changed from default. Before the default was create
a
> > > new session. Now I think this is not the default.
> > >
> > > Please try to use:
> > > xmlns:xsp-session="http://apache.org/xsp/session/2.0"
> >create-session="true"
> > >
> > > Best Regards,
> > >
> > > Antonio Gallardo
> > >
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> > > For additional commands, e-mail: cocoon-users-help@xml.apache.org
> > >
> > >
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> >For additional commands, e-mail: cocoon-users-help@xml.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Mime
View raw message