-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Added a brief explanation about Doctrine DBAL Session Storage #5019
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
Conversation
|
||
The only significant disadvantage of the Doctrine DBAL session storage comparing | ||
it with ``PdoSessionHandler`` is that you can only configure the name of the | ||
table used to store sessions, but not its column names. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i am not sure of the comma here
There was already a PR on this: #3914 We should pick the best things of both PRs and have one PR. /cc @xocasdashdash |
@wouterj I'm sorry about that. Can we develop a bot that automatically applies the |
above, but uses a Doctrine connection and thus also works with non-PDO-based | ||
drivers like mysqli and OCI8. | ||
|
||
The only significant disadvantage of the Doctrine DBAL session storage comparing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note that these paragraphs are true for 2.3, but not for 2.6+ (the DBAL session storage has not been migrated to implement session locking yet AFAIK)
Closing it because there is another previous PR to fix this issue. |
Reopening it because the other previous PR was closed precisely in favor of this PR. |
What's left for this PR to be considered finished? |
)); | ||
|
||
// ... | ||
$container->setParameter('pdo.dbal_session_table', 'sess'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The other examples don't have the pdo.
prefix.
I actually dislike that we're giving people two equivalent options (or maybe this is not as good as the PDO option, since it doesn't have the new locking stuff). I'd like to not document this - since it doesn't add anything, it takes away. Also, the biggest potential advantage - reusing the dbal connection - is not a good idea, according to the original PR: symfony/symfony#2182 (comment) Anyone else agree? |
the DBAL implementation made sense in 2.3 because it allowed to lazy-load the connection. but the new 2.6+ PDO implementation also supports lazy-loading the PDO connection, so it is indeed less necessary. |
Thanks Stof - I'm going to leave this as a "will not document" |
This PR fixes one of the oldest pending issues, dating back to Nov. 2011 :)