Closed
Description
This file depends on the Mongo, MongoClient, MongoId, MongoDate, and MongoBinData classes that are no longer present in the new MongoDB extension, see here
I've made this gist that utilizes the new classes.
Steps to reproduce this issue:
- Create & Load a session that is stored in MongoDB using the original PHP MongoDB driver
- Observe that the session is created and loaded as expected
- Uninstall the Mongo extension in PHP and install the MongoDB extension in it's place.
- Create a session and attempt to store it in MongoDB
- Observe that this process fails with the error
MongoClient or Mongo instance required
. This exception is found onLine 73
ofSymfony\Component\HttpFoundation\Session\Storage\Handler\MongoDbSessionHandler
.
I'd suggest modifying this file to have the ability to work with both PHP extensions depending on which classes exist.