How to check if a session is invalid

前端 未结 3 1903
天命终不由人
天命终不由人 2020-12-13 04:39

How to check if a session is invalid or not? There is no method in the API.

Is it the same as isNew()? And what is the difference if not?

3条回答
  •  一个人的身影
    2020-12-13 04:59

    isNew() is true only if this session wasn't yet accepted by client (i.e. it was just created, and JSESSIONID wasn't sent yet, or if it was sent, client didn't send it back, so server doesn't know about it and created another session)

提交回复
热议问题