[Klone-users] Issue with session functions
Stefano Barbato
barbato at koanlogic.com
Wed Dec 5 17:14:10 EST 2007
Hi Sylvain,
On 05/dic/07, at 20:36, centraladmin at lahiette.com wrote:
> Hi all,
> I am currently evaluationg the klone solution compared to other
> embedded
> HTTP libraries and i find it very impressive.
> Now, i am doing some tests with the "session" feature, and i am not
> able
> to compile some simple test code ! I guess my current issue is
> related to
> GCC 4.2.1, but i just want to be sure: could you post here a real .kl1
> example with session_get/session_set ?
>
> Thanks, Sylvain.
sure, an example is attached.
Note that you can change the way KLone stores sessions changing (or
setting) the session.type key in the configuration file and tweaking
session options accordingly:
"file" sessions are stored in the filesystem (/tmp/klone_sess*); if
"memory" is used all sessions data is kept in memory so devices with
no storage can still use sessions.
"client" sessions are stored as cookies on the client; session data is
compressed and encrypted in a way that only the server will be able to
read them back.
---[ kloned.conf ]---
server_list mysrv
...
mysrv
{
...
session
{
# use "file", "memory" or "client"
type client
# options for in-memory session
memory
{
max_count 10
limit 1024
}
# options for client-side sessions
client
{
encrypt yes
compress yes
}
}
...
}
...
---------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: index.kl1
Type: application/octet-stream
Size: 1053 bytes
Desc: not available
Url : http://koanlogic.com/pipermail/klone-users/attachments/20071205/7b41f5b0/index.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kloned.conf
Type: application/octet-stream
Size: 712 bytes
Desc: not available
Url : http://koanlogic.com/pipermail/klone-users/attachments/20071205/7b41f5b0/kloned.obj
More information about the klone-users
mailing list