This PR contains the work done to do a little bit of housekeeping pass across all packages and the Website service. To provide further details about the work: * Refreshed the READMEs and source documentation to match the current code; * Tagged every test case consistently across the Infrastructure, Localization, Persistence, and Website test targets; * Removed Website middleware tests now covered by Infrastructure's own suite; * Conformed the `PrepareDB` method to Sendable; * Relaxes the production Compose DATABASE_TLS default from require to prefer; * Added Persistence test verifying the prefer posture falls back to plaintext connections. Reviewed-on: rock-n-code/loud-amsterdam#27 Co-authored-by: Javier Cicchelli <javier@rock-n-code.com> Co-committed-by: Javier Cicchelli <javier@rock-n-code.com>
18 lines
773 B
Swift
18 lines
773 B
Swift
/// The persistence backend the service runs against.
|
|
///
|
|
/// The executable picks a driver at startup and hands it to ``Service``, which registers the matching database as the default one. Repositories resolve
|
|
/// that default and stay agnostic of which backend is in use.
|
|
public enum Driver: Sendable {
|
|
|
|
/// A MySQL/MariaDB server, reached with the given connection parameters.
|
|
///
|
|
/// - Parameter configuration: the host, credentials, TLS posture, and pooling limits the connection is opened with.
|
|
case mysql(Configuration)
|
|
|
|
/// An ephemeral, in-process SQLite database held entirely in memory.
|
|
///
|
|
/// Nothing is written to disk, and all data is lost when the service stops — intended for local development and tests.
|
|
case inMemory
|
|
|
|
}
|