It forces InvalidStateException if session was invalidated. It's hacky but these is no public isValid(). Very open to other ideas!