session manager with sqlite