implement the save session