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

Session stored in cookie #14802

Open
FroMage opened this issue Feb 3, 2021 · 9 comments
Open

Session stored in cookie #14802

FroMage opened this issue Feb 3, 2021 · 9 comments
Labels
area/vertx kind/enhancement New feature or request

Comments

@FroMage
Copy link
Member

FroMage commented Feb 3, 2021

I can't find any issue about this, even though we discussed this in the past a lot.

It'd be nice to finally have a session cookie, signed, where we can store plain text stuff such as:

  • the flash scope
  • the current user locale

This will mostly be useful for Qute users, but they exist, so… :)

See #14794

The question is where would this live, given that cookies come from vert.x, this is not really core. Though we could make an SPI if some users want to store their session data elsewhere, but I really don't want to start encouraging session usage besides cookies…

@FroMage FroMage added the kind/enhancement New feature or request label Feb 3, 2021
@ghost ghost added the triage/needs-triage label Feb 3, 2021
@mkouba
Copy link
Contributor

mkouba commented Dec 5, 2022

I wonder if this should go into quarkus core or whether it could be a quarkus-renarde feature?

@cescoffier
Copy link
Member

@Ladicek For your awareness as it's related to #36310

@Ladicek
Copy link
Contributor

Ladicek commented Oct 9, 2023

My personal opinion is the exact opposite: session data should just be stored server-side and stuffing them into cookies is a last resort kind of thing. Vert.x Web has a cookie session store, which I intentionally choose to not support in #36310, but it would be the proper solution. It supports signing but not encryption, so it requires even more care than regular Vert.x Web sessions.

@cescoffier
Copy link
Member

@Ladicek do you think we could move your PR forward? It's not about cookies, but if we could have session storage, it would cover a part of the problem.

@Ladicek
Copy link
Contributor

Ladicek commented Nov 6, 2024

I don't think anything has changed on the Vert.x Web side, so the danger of concurrent session access is still present.

@cescoffier
Copy link
Member

Just a note: I will add this to the "2025 roadmap" (basically, things we would like to have in 2025). So, expect some work on that later this year.

@Ladicek
Copy link
Contributor

Ladicek commented Jan 22, 2025

I wonder if you're aware of the work @pferraro is doing on Vert.x Web SessionStore implementation based on the WildFly clustered session manager. Or, more generally, what kind of sessions do we actually want in Quarkus, and how should they behave [1].

[1] Vert.x Web built-in SessionStore implementations don't guard against concurrent access, while the WildFly session manager does, I think (not 100% sure).

@cescoffier
Copy link
Member

@Ladicek Thanks, no, I was not aware of that work!

About the behavior, I still need time to wrap my head around and write some proposals.

@Ladicek
Copy link
Contributor

Ladicek commented Jan 24, 2025

OK, I think we should meet with @pferraro and talk, then. There's non-trivial difference between how sessions work in Vert.x Web and WildFly and if anything, lessons that can be learned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/vertx kind/enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants