home *** CD-ROM | disk | FTP | other *** search
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Copyright 1999-2004 The Apache Software Foundation
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
- <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.0//EN" "document-v10.dtd">
- <document>
- <header>
- <title>Session Management</title>
- <authors>
- <person name="Carsten Ziegeler" email="cziegeler@s-und-n.de"/>
- </authors>
- </header>
- <body>
- <s1 title="Introduction">
- <p>This chapter describes the basic Cocoon session management using
- the session transformer.</p>
-
- <p>The chapter "Special Contexts" explains some special
- contexts which do not require a session. They are available everytime. These
- special contexts are the request context and the
- temporary context.</p>
- </s1>
- <s1 title="Session Tracking">
- <p>If a user has a session, Cocoon is able to connect new requests from this user
- to the session of the user. This is done by session tracking. Basically,
- the session tracking of Cocoon uses the session tracking of the environment,
- which is usually the servlet engine.
- </p>
- <p>There are two methods for session tracking: cookies and url rewriting. If you
- use cookies, you don't have to care about session tracking. Just refer to
- the documentation of your servlet engine on how to turn on cookies for session
- handling.</p>
- <p>URL rewriting instead is a little bit complicated. For url rewriting, each link
- the user can select, needs a special session ID appended to this link.
- Unfortunately, this is not done automatically by Cocoon or the servlet engine.
- You can either do this by hand or you can use the <em>encodeURL</em> transformer
- just before the <em>html serializer</em>.
- </p>
- </s1>
- <s1 title="Sessions">
- <p>The session action is responsible for creating and
- terminating a session. It is controlled by a sitemap parameter named "action".
- This parameter can have the values "create" and "terminate". If no parameter is
- set, it defaults to "create".</p>
- <p>The action either creates a new session immediately (if not already
- available), or terminates it (if available).</p>
- </s1>
- </body>
- </document>
-