Week 20
News
Hello Vapor-heads of the world!. The final Fluent 3 RCs were released this week and it comes with very interesting changes and improvements. Big steps towards code sharing, first tests of using Fluent ORM with the internal SQLite DB on iOS ✅
New Features
Add CaseIterable protocol for Swift 4.1
This will allow Fluent to take advantage of CaseIterable when it comes in Swift 4.2.
Fluent 1.0.0 GM + Add Decoders + SQL Updates
NIO
Current version 1.8.0
Updated http_parser
Motivation:
Our copy of http_parser
has become almost a year old now, and there are
both some bugfixes that improve correctness and some performance
improvements in http_parser
that we should pick up.
Modifications:
- Updated http_parser
- Added tests to confirm we don’t suffer from nodejs/http-parser#432
- Added tests that we didn’t get broken by SOURCE verb addition.
Result:
Shiny new http_parser!
Community Contributions
Created Worker.future() method
Adds a .future() method to the Worker protocol that creates a new, succeeded, future with a Void value.
let success: Future<Void> = request.future()
Added helper method to initialize connection from connection string
let databaseURL = "mysql://username:password@hostname.com:3306/database"
let config = try MySQLDatabaseConfig(url: databaseURL)
Added PostgreSQLStringModel
Make FluentSQLite usable on iOS
The two most popular options for persistence on iOS (Realm and Core Data), both rely heavily on Objective-C, however, SQLite is available.
Concept:
// Shared models package, imported by both client and server
class User: Codable {
let id: Int?
let name: String
let age: Int
}
// Client
extension User: SQLiteModel, Migration {}
// Server
extension User: PostgresModel, Migration {}
Tagged releases
Current Version 3.0.4
- Core 3.3.0
- DatabaseKit 1.1.0
- SQLite 3.0.0 RC 3
- MySQL 3.0.0 RC 3
- PostgreSQL 1.0.0 RC 3.0.1
- Fluent 3.0.0 RC 3.0.1
- Fluent SQLite 3.0.0 RC 3
- Fluent MySQL 3.0.0 RC 3
- Fluent PostgreSQL 1.0.0 RC 3.0.1
- Redis 3.0.0 RC 3
- Auth 2.0.0 RC 5
Articles
How to build Web Auth with Session
Brought to you by @martinlasek
How to build Web Auth with Session
Fluent Migrations: Adding/Deleting columns from a Database
Brought to you by @anapaix
Fluent Migrations: Adding/Deleting columns from a Database
Want to know more or get inspired?
- Check out what we are working on now. You might see something you can collaborate with Issues
- Check out more Vapor awesomeness Awesome Vapor
- Some more Vapor learning material Vapor School
- Great resources from our community Vapor Forum
- Vapor’s Core team had published an early access book on Vapor through RW here
- Paul Hudson had also updated his Server Side Swift with Vapor book here
- Also the RW’s Vapor Video Course Server Side Swift with Vapor - Video Course
- Vapor Forum Vapor Forum
- Vapor Forum @swift.org Vapor@swift.org
Take action
There are many ways you can contribute with Vapor
- Star the project in GitHub
- Follow us on Twitter
- Follow us on Medium
- Become a backer
- Become a sponsor
- Come and talk to us