You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Josh2007 <jo...@gmail.com> on 2008/04/09 10:07:23 UTC
2.2 trunk - Servlet Service set attribute in global session but
lose it at next servlet call.
Hello,
I have a main block (block-a) which makes calls to a depend block (block-b).
Block-b has access to the global session.
At the first call from block-a, block-b creates a session-attribute "test".
I noticed this session-attribute can be retrieved within block-b (right
after setting it), but not within block-a.
At the second call from block-a, block-b needs to read the session-attribute
"test" it has created at the first call, but cannot find it anymore:
session-attr "test" doesn't exists.
My question:
Does it mean, you can set up a session-attribute in a dependent block only
available for the time of the request? Which means if I make another request
the session-attribute will not be available anymore?
Is there a way to set a session-attribute in a dependent block and make it
available for the duration of the global session?
Thanks,
Josh
My Cocoon blocks version:
cocoon-core: 2.2.1-SNAPSHOT
cocoon-servlet-service-components: 1.1.0-SNAPSHOT
cocoon-template-impl: 1.2.0-SNAPSHOT
cocoon-flowscript-impl: 1.1.0-SNAPSHOT
--
View this message in context: http://www.nabble.com/2.2-trunk---Servlet-Service-set-attribute-in-global-session-but-lose-it-at-next-servlet-call.-tp16581722p16581722.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: 2.2 trunk - Servlet Service set attribute in global session but
lose it at next servlet call.
Posted by Josh2007 <jo...@gmail.com>.
Reinhard, thanks for your quick reply.
I created a new issue:
COCOON-2194
Session-attr set in dependency blocks destroyed after servlet call.
Regards,
Josh
Reinhard Poetz wrote:
>
> Josh2007 wrote:
>> Hello,
>>
>> I have a main block (block-a) which makes calls to a depend block
>> (block-b).
>>
>> Block-b has access to the global session.
>>
>> At the first call from block-a, block-b creates a session-attribute
>> "test".
>> I noticed this session-attribute can be retrieved within block-b (right
>> after setting it), but not within block-a.
>>
>> At the second call from block-a, block-b needs to read the
>> session-attribute
>> "test" it has created at the first call, but cannot find it anymore:
>> session-attr "test" doesn't exists.
>>
>> My question:
>> Does it mean, you can set up a session-attribute in a dependent block
>> only
>> available for the time of the request? Which means if I make another
>> request
>> the session-attribute will not be available anymore?
>>
>> Is there a way to set a session-attribute in a dependent block and make
>> it
>> available for the duration of the global session?
>>
>> Thanks,
>>
>> Josh
>>
>> My Cocoon blocks version:
>> cocoon-core: 2.2.1-SNAPSHOT
>> cocoon-servlet-service-components: 1.1.0-SNAPSHOT
>> cocoon-template-impl: 1.2.0-SNAPSHOT
>> cocoon-flowscript-impl: 1.1.0-SNAPSHOT
>
> Sounds like a bug :-(
> Can you file a report please?
>
> --
> Reinhard Pötz Managing Director, {Indoqa} GmbH
> http://www.indoqa.com/en/people/reinhard.poetz/
>
> Member of the Apache Software Foundation
> Apache Cocoon Committer, PMC member, PMC Chair reinhard@apache.org
> _________________________________________________________________________
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>
--
View this message in context: http://www.nabble.com/2.2-trunk---Servlet-Service-set-attribute-in-global-session-but-lose-it-at-next-servlet-call.-tp16581722p16583882.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: 2.2 trunk - Servlet Service set attribute in global session but
lose it at next servlet call.
Posted by Reinhard Poetz <re...@apache.org>.
Josh2007 wrote:
> Hello,
>
> I have a main block (block-a) which makes calls to a depend block (block-b).
>
> Block-b has access to the global session.
>
> At the first call from block-a, block-b creates a session-attribute "test".
> I noticed this session-attribute can be retrieved within block-b (right
> after setting it), but not within block-a.
>
> At the second call from block-a, block-b needs to read the session-attribute
> "test" it has created at the first call, but cannot find it anymore:
> session-attr "test" doesn't exists.
>
> My question:
> Does it mean, you can set up a session-attribute in a dependent block only
> available for the time of the request? Which means if I make another request
> the session-attribute will not be available anymore?
>
> Is there a way to set a session-attribute in a dependent block and make it
> available for the duration of the global session?
>
> Thanks,
>
> Josh
>
> My Cocoon blocks version:
> cocoon-core: 2.2.1-SNAPSHOT
> cocoon-servlet-service-components: 1.1.0-SNAPSHOT
> cocoon-template-impl: 1.2.0-SNAPSHOT
> cocoon-flowscript-impl: 1.1.0-SNAPSHOT
Sounds like a bug :-(
Can you file a report please?
--
Reinhard Pötz Managing Director, {Indoqa} GmbH
http://www.indoqa.com/en/people/reinhard.poetz/
Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member, PMC Chair reinhard@apache.org
_________________________________________________________________________
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org