Instance Methodhummingbird 2.1.0Hummingbird
runService(gracefulShutdownSignals:)
Helper function that runs application inside a ServiceGroup which will gracefully shutdown on signals SIGINT, SIGTERM
Application.swift:148func runService(gracefulShutdownSignals: [UnixSignal] = [.sigterm, .sigint]) async throws
Other members in extension
Typealiases
typealias Context
Context passed with Request to responder
Instance members
var configuration: ApplicationConfiguration
Default Configuration
var eventLoopGroup: EventLoopGroup
Default event loop group used by application
var logger: Logger
Default Logger
var processesRunBeforeServerStart: [() async throws -> Void]
Default to no processes being run before the server is setup
var server: HTTPServerBuilder
Server channel setup
var services: [any Service]
Default to no extra services attached to the application.
func onServerRunning(Channel
) async Default onServerRunning that does nothing
func run(
) async throws Construct application and run it