@@ -19,7 +19,7 @@ import NIOCore
19
19
/// `LambdaRuntime` manages the Lambda process lifecycle.
20
20
///
21
21
/// Use this API, if you build a higher level web framework which shall be able to run inside the Lambda environment.
22
- public final class LambdaRuntime < Handler: NonInitializingByteBufferLambdaHandler > {
22
+ public final class LambdaRuntime < Handler: LambdaRuntimeHandler > {
23
23
private let eventLoop : EventLoop
24
24
private let shutdownPromise : EventLoopPromise < Int >
25
25
private let logger : Logger
@@ -200,7 +200,7 @@ public final class LambdaRuntime<Handler: NonInitializingByteBufferLambdaHandler
200
200
private enum State {
201
201
case idle
202
202
case initializing
203
- case active( LambdaRunner , any NonInitializingByteBufferLambdaHandler )
203
+ case active( LambdaRunner , any LambdaRuntimeHandler )
204
204
case shuttingdown
205
205
case shutdown
206
206
@@ -252,7 +252,7 @@ public enum LambdaRuntimeFactory {
252
252
_ handlerType: Handler . Type ,
253
253
eventLoop: any EventLoop ,
254
254
logger: Logger
255
- ) -> LambdaRuntime < some NonInitializingByteBufferLambdaHandler > {
255
+ ) -> LambdaRuntime < some LambdaRuntimeHandler > {
256
256
LambdaRuntime< CodableLambdaHandler< Handler>>(
257
257
handlerProvider: CodableLambdaHandler< Handler> . makeHandler( context: ) ,
258
258
eventLoop: eventLoop,
@@ -271,7 +271,7 @@ public enum LambdaRuntimeFactory {
271
271
_ handlerType: Handler . Type ,
272
272
eventLoop: any EventLoop ,
273
273
logger: Logger
274
- ) -> LambdaRuntime < some NonInitializingByteBufferLambdaHandler > {
274
+ ) -> LambdaRuntime < some LambdaRuntimeHandler > {
275
275
LambdaRuntime< CodableEventLoopLambdaHandler< Handler>>(
276
276
handlerProvider: CodableEventLoopLambdaHandler< Handler> . makeHandler( context: ) ,
277
277
eventLoop: eventLoop,
@@ -290,7 +290,7 @@ public enum LambdaRuntimeFactory {
290
290
_ handlerType: Handler . Type ,
291
291
eventLoop: any EventLoop ,
292
292
logger: Logger
293
- ) -> LambdaRuntime < some NonInitializingByteBufferLambdaHandler > {
293
+ ) -> LambdaRuntime < some LambdaRuntimeHandler > {
294
294
LambdaRuntime < Handler > (
295
295
handlerProvider: Handler . makeHandler ( context: ) ,
296
296
eventLoop: eventLoop,
@@ -301,11 +301,11 @@ public enum LambdaRuntimeFactory {
301
301
/// Create a new `LambdaRuntime`.
302
302
///
303
303
/// - parameters:
304
- /// - handlerProvider: A provider of the ``CoreByteBufferLambdaHandler `` the `LambdaRuntime` will manage .
304
+ /// - handlerProvider: A provider of the ``LambdaRuntimeHandler `` the `LambdaRuntime` will call to create the handler .
305
305
/// - eventLoop: An `EventLoop` to run the Lambda on.
306
306
/// - logger: A `Logger` to log the Lambda events.
307
307
@inlinable
308
- public static func makeRuntime< Handler: NonInitializingByteBufferLambdaHandler > (
308
+ public static func makeRuntime< Handler: LambdaRuntimeHandler > (
309
309
handlerProvider: @escaping ( LambdaInitializationContext ) -> EventLoopFuture < Handler > ,
310
310
eventLoop: any EventLoop ,
311
311
logger: Logger
@@ -320,11 +320,11 @@ public enum LambdaRuntimeFactory {
320
320
/// Create a new `LambdaRuntime`.
321
321
///
322
322
/// - parameters:
323
- /// - handlerProvider: A provider of the ``CoreByteBufferLambdaHandler `` the `LambdaRuntime` will manage .
323
+ /// - handlerProvider: A provider of the ``LambdaRuntimeHandler `` the `LambdaRuntime` will call to create the handler .
324
324
/// - eventLoop: An `EventLoop` to run the Lambda on.
325
325
/// - logger: A `Logger` to log the Lambda events.
326
326
@inlinable
327
- public static func makeRuntime< Handler: NonInitializingByteBufferLambdaHandler > (
327
+ public static func makeRuntime< Handler: LambdaRuntimeHandler > (
328
328
handlerProvider: @escaping ( LambdaInitializationContext ) async throws -> Handler ,
329
329
eventLoop: any EventLoop ,
330
330
logger: Logger
0 commit comments