Implementing session handlers in the backend