Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem for Invalidation/Expiration Callback. #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

imcharsi
Copy link

Hi.

At first, My English is poor. I'm sorry about that.

While I tried this spray-session, I thought that I found something strange behavior.

In this implementation, we can register arbitrary callbacks for session invalidation/expiration.

So I tried this. In InMemorySessionManager's session expiration, It looks like that this callback was not called.

My idea about why is

  1. Start at CleanUp in Here
  2. Delete the expired session from session map in Here
  3. The code try to find the already deleted session in session map in Here

My suggestion is

case class Invalidate(String, Option[Map[String, Session[T]]])

instead of

case class Invalidate(String)

Thanks.

@imcharsi
Copy link
Author

P.S.
I didn't write any test about this suggestion.
Sorry about that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants