red-black tree, session
added session management