Session scope #241
Answered
by
Tishka17
dineshbvadhia
asked this question in
Q&A
Session scope
#241
-
A user makes multiple requests during their session. The previous request is stored as a dependency injection ie. if request#2 is sent, request#1 is read from the DI. On completion, request#1 is overwritten with request#2 in the DI and so on until the user exits the session. Is this possible with dishka? |
Beta Was this translation helpful? Give feedback.
Answered by
Tishka17
Sep 12, 2024
Replies: 1 comment 6 replies
-
It is not clear how are you going to use those requests. Another question is whether requests can be concurrent or not |
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Ok, it sounds a bit away from problems which are solved by dishka.
In dishka Scope.SESSION is something which exists in your app while other requests are running. It is ok for websocket connections or something like that.
In regular web apps HTTP-Session is data which is shared among requests. You can have multiple application instances, they cvan be restarted. Session exists regardless on that.
So, I suppose you have to deal with this date in your application or presentation logic