You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The MongoDB PHP team is happy to announce that version 5.0.0 of the MongoDB integration for Laravel is now available. This is a release candidate for which we'd like to receive your feedback.
Breaking changes for better compatibility with Laravel and Eloquent
id is always alias to _id in MongoDB. You can remove the protected $primaryKey = '_id' in model classes. Replace all $model->_id with $model->id.
DateTimeInterface objects (including Carbon) are converted to MongoDB UTCDateTime by the query builder in queries, inserted and updated data. In results, MongoDB UTCDateTime objects are automatically converted to Carbon date with the default timezone. Some Eloquent cast my no longer be required.
Results of the Query Builder are returned as stdClass instead of array. Replace code like $item['name'] with $item->name.
$collection is replaced by $table to customize the name of an Eloquent Model.
The providers Auth\PasswordResetServiceProvider, MongoDBQueueServiceProvider and Queue\Failed\MongoFailedJobProvider are removed. Remove them from your application. The MongoDB connection is compatible with the Laravel classes
MongoDB\Laravel\Connection is replaced by MongoDB\Connection, and query are logged using MongoDB Monitoring Events.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
The MongoDB PHP team is happy to announce that version 5.0.0 of the MongoDB integration for Laravel is now available. This is a release candidate for which we'd like to receive your feedback.
Breaking changes for better compatibility with Laravel and Eloquent
idis always alias to_idin MongoDB. You can remove theprotected $primaryKey = '_id'in model classes. Replace all$model->_idwith$model->id.DateTimeInterfaceobjects (includingCarbon) are converted to MongoDBUTCDateTimeby the query builder in queries, inserted and updated data. In results, MongoDBUTCDateTimeobjects are automatically converted toCarbondate with the default timezone. Some Eloquent cast my no longer be required.stdClassinstead ofarray. Replace code like$item['name']with$item->name.$collectionis replaced by$tableto customize the name of an Eloquent Model.Auth\PasswordResetServiceProvider,MongoDBQueueServiceProviderandQueue\Failed\MongoFailedJobProviderare removed. Remove them from your application. The MongoDB connection is compatible with the Laravel classesMongoDB\Laravel\Connectionis replaced byMongoDB\Connection, and query are logged using MongoDB Monitoring Events.What's Changed
New Features
idan alias for_idby @GromNaN in PHPORM-147 Makeidan alias for_id#3040Other Changes
Blueprint::background()by @GromNaN in PHPORM-157 RemoveBlueprint::background()#3132New Contributors
Full Changelog: 4.8.0...5.0.0
This discussion was created from the release 5.0.0.
Beta Was this translation helpful? Give feedback.
All reactions