[FrameworkBundle] Allow to set null for the handler in NativeSessionStorage#5290
Conversation
Contributor
|
👍 |
fabpot
added a commit
that referenced
this pull request
Aug 18, 2012
Commits ------- 8e11aaa [FrameworkBundle] Allow to set null for the handler in NativeSessionStorage Discussion ---------- [FrameworkBundle] Allow to set null for the handler in NativeSessionStorage Bug fix: no Feature addition: yes (ok for RC) Backwards compatibility break: yes Symfony2 tests pass: yes Fixes the following tickets: 5267 Todo: ~ License of the code: MIT Documentation PR: ~ Refs #5267 Adds the following configuration ``` session: handler_id: ~ ``` Which allows the configuration of the session not to use any save handler and therefor just use whatever save_handler is set in `php.ini` --------------------------------------------------------------------------- by dlsniper at 2012-08-17T17:24:37Z :+1:
Member
There was a problem hiding this comment.
this should be a strict comparison
nicolas-grekas
added a commit
that referenced
this pull request
Mar 28, 2023
…id is null (nicolas-grekas)
This PR was merged into the 5.4 branch.
Discussion
----------
[FrameworkBundle] Fix wiring session.handler when handler_id is null
| Q | A
| ------------- | ---
| Branch? | 5.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | -
| License | MIT
| Doc PR | -
When the session `handler_id` is null, we currently set the `$handler` argument of the storage/factory services to null, which means to them "create your own handler internally from the native one". This means that the `session.handler` service is "a lie": it's not the real handler used by the storage. It also means that the `%session.save_path%` parameter is lying too, because it is set to `%kernel.cache_dir%/sessions` (by default), while the storage will use `ini_get('session.save_path')` in practice.
This issue is 10 years old... #5290
Commits
-------
e23be58 [FrameworkBundle] Fix wiring session.handler when handler_id is null
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug fix: no
Feature addition: yes (ok for RC)
Backwards compatibility break: yes
Symfony2 tests pass: yes
Fixes the following tickets: 5267
Todo: ~
License of the code: MIT
Documentation PR: ~
Refs #5267
Adds the following configuration
Which allows the configuration of the session not to use any save handler and therefor just use whatever save_handler is set in
php.ini