Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 575ba15

Browse filesBrowse files
committed
feature #24389 [DoctrineBridge] Deprecate dbal session handler (Tobion)
This PR was merged into the 3.4 branch. Discussion ---------- [DoctrineBridge] Deprecate dbal session handler | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | no | New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files --> | BC breaks? | no | Deprecations? | yes | Tests pass? | yes | Fixed tickets | #20501 | License | MIT | Doc PR | The DbalSessionHandler misses all the improvements from the PdoSessionHandler (lock modes, delayed GC, configurable naming). The only advantage it had was the ability to work with non-pdo drivers. But since DBAL requires PDO now as well (doctrine/dbal@36df682) even that is not really relevant anymore. Stofs argument in #20501 (comment) sound like a new feature that can be implemented separately. Ref. #24267 Commits ------- ffc74eb [DoctrineBridge] Deprecate DbalSessionHandler
2 parents 02b77f5 + ffc74eb commit 575ba15
Copy full SHA for 575ba15

File tree

3 files changed

+10
-0
lines changed
Filter options

3 files changed

+10
-0
lines changed

‎src/Symfony/Bridge/Doctrine/HttpFoundation/DbalSessionHandler.php

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Doctrine/HttpFoundation/DbalSessionHandler.php
+4Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111

1212
namespace Symfony\Bridge\Doctrine\HttpFoundation;
1313

14+
@trigger_error(sprintf('The class %s is deprecated since version 3.4 and will be removed in 4.0. Use Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler instead.', DbalSessionHandler::class), E_USER_DEPRECATED);
15+
1416
use Doctrine\DBAL\Connection;
1517
use Doctrine\DBAL\Driver\DriverException;
1618
use Doctrine\DBAL\Driver\ServerInfoAwareConnection;
@@ -25,6 +27,8 @@
2527
* @author Fabien Potencier <fabien@symfony.com>
2628
* @author Johannes M. Schmitt <schmittjoh@gmail.com>
2729
* @author Tobias Schultze <http://tobion.de>
30+
*
31+
* @deprecated since version 3.4, to be removed in 4.0. Use Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler instead.
2832
*/
2933
class DbalSessionHandler implements \SessionHandlerInterface
3034
{

‎src/Symfony/Bridge/Doctrine/HttpFoundation/DbalSessionHandlerSchema.php

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Doctrine/HttpFoundation/DbalSessionHandlerSchema.php
+4Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,16 @@
1111

1212
namespace Symfony\Bridge\Doctrine\HttpFoundation;
1313

14+
@trigger_error(sprintf('The class %s is deprecated since version 3.4 and will be removed in 4.0. Use Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler::createTable instead.', DbalSessionHandlerSchema::class), E_USER_DEPRECATED);
15+
1416
use Doctrine\DBAL\Schema\Schema;
1517

1618
/**
1719
* DBAL Session Storage Schema.
1820
*
1921
* @author Johannes M. Schmitt <schmittjoh@gmail.com>
22+
*
23+
* @deprecated since version 3.4, to be removed in 4.0. Use Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler::createTable instead.
2024
*/
2125
final class DbalSessionHandlerSchema extends Schema
2226
{

‎src/Symfony/Bridge/Doctrine/Tests/HttpFoundation/DbalSessionHandlerTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Doctrine/Tests/HttpFoundation/DbalSessionHandlerTest.php
+2Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
* Test class for DbalSessionHandler.
1919
*
2020
* @author Drak <drak@zikula.org>
21+
*
22+
* @group legacy
2123
*/
2224
class DbalSessionHandlerTest extends TestCase
2325
{

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.