ibatis-user-cs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gilles Bayon" <ibatis....@gmail.com>
Subject Re: Writing a custom session store by implementing ISessionStore
Date Mon, 09 Oct 2006 17:21:30 GMT
A CallContextSessionStore is not 100% safe in web environnement.

A better solution in your thread code is :

MyBackgroundCodeTask()
{
   IDalSession session = sqlMapper.CreateSqlMapSession();
   session.OpenConnection();
   IMappedStatement myStatement = GetMappedStatement("statementName",
parameterObject);

  ... myStatement.ExecuteQueryForObject(session, parameterObject);

  session.CloseConnection();

}


-- 
Cheers,
Gilles

<a href="http://www.amazon.com/gp/registry/6JCP7AORB0LE">Wish List</a>

Mime
View raw message