Releases: vapor/fluent
Release Candidate 1
Updates to Swift 5.2.
Release candidates represent the final shift toward focusing on bug fixes and documentation. Breaking changes will only be accepted for critical issues. We expect a final release of this package shortly after Swift 5.2's release date.
Fluent Beta 3
- Now compatible with latest Vapor beta 4 and FluentKit beta 5
Export Custom Operators
Provides a workaround for SR-12132 which causes custom operators defined in FluentKit
to not be exported correctly (fixes vapor/fluent-kit#144, #656)
Custom operators for String filtering will now be available by importing just Fluent
:
~~
: Value contains string=~
: Value has string prefix~=
: Value has string suffix!~
: Value doesn't contain string!=~
: Value doesn't have string prefix!~=
: Value doesn't have string suffix
As well as operators for Array filtering:
~~
: Value in array!~
: Value not in array
Add ModelUser and ModelUserToken
Adds two new protocols ModelUser
and ModelUserToken
for easily implementing basic and bearer authentication using Fluent models. Docs will be available at https://docs.vapor.codes/4.0/fluent/authentication/
Add autoMigrate and autoRevert methods
Adds autoMigrate
and autoRevert
methods to Application
. These methods allow for programmatically running the equivalent of --auto-migrate
and --auto-revert
.
try app.autoMigrate().wait()
These methods are useful when working with ephemeral databases like in-memory SQLite and for testing.
Pagination
Implements pagination helpers using new APIs from vapor/fluent-kit#130.
struct TodoController {
func index(req: Request) throws -> EventLoopFuture<Page<Todo>> {
Todo.query(on: req.db).paginate(for: req)
}
}
Fluent 4.0.0 Beta 2
Updated to latest Vapor and FluentKit beta 2 changes.
Fluent 4.0.0 Beta 1
- Added
DatabaseSessions
andSession
models for storing Vapor request sessions in your database. (#645) - Added
Request.db
helper for accessing request-specific database context.
Fluent 3.2.1
Fluent 4.0.0 Alpha 2.1
- Updates to ConsoleKit 4.0.0 Alpha 2 (#641 )
Notes: This updated ConsoleKit release includes property wrapper support and internal cleanup. Fluent's
MigrateCommand
, and--auto-migrate
and--auto-revert
flags have been updated to use the new syntax.