Revert "session handling updates"

This reverts commit c68d0c7a349cda051ec103a07f233ae5c5654dee.
Revert "Revert "session handling updates""

This reverts commit 7a725b1b81c0ab32851a4cdc19866c65bf8ce84e.