Refactoring of SimpleSession