File tree 2 files changed +8
-2
lines changed
Sources/AWSLambdaRuntimeCore
2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -47,12 +47,12 @@ jobs:
47
47
# https://github.com/swiftlang/github-workflows/issues/34
48
48
musl :
49
49
runs-on : ubuntu-latest
50
- container : swift:6.0-noble
50
+ container : swift:6.0.2 -noble
51
51
timeout-minutes : 30
52
52
steps :
53
53
- name : Check out code
54
54
uses : actions/checkout@v4
55
55
- name : Install SDK
56
- run : swift sdk install https://download.swift.org/swift-6.0.1 -release/static-sdk/swift-6.0.1 -RELEASE/swift-6.0.1 -RELEASE_static-linux-0.0.1.artifactbundle.tar.gz --checksum d4f46ba40e11e697387468e18987ee622908bc350310d8af54eb5e17c2ff5481
56
+ run : swift sdk install https://download.swift.org/swift-6.0.2 -release/static-sdk/swift-6.0.2 -RELEASE/swift-6.0.2 -RELEASE_static-linux-0.0.1.artifactbundle.tar.gz --checksum aa5515476a403797223fc2aad4ca0c3bf83995d5427fb297cab1d93c68cee075
57
57
- name : Build
58
58
run : swift build --swift-sdk x86_64-swift-linux-musl
Original file line number Diff line number Diff line change @@ -33,6 +33,12 @@ public final class LambdaRuntime<Handler>: @unchecked Sendable where Handler: St
33
33
) {
34
34
self . handlerMutex = NIOLockedValueBox ( handler)
35
35
self . eventLoop = eventLoop
36
+
37
+ // by setting the log level here, we understand it can not be changed dynamically at runtime
38
+ // developers have to wait for AWS Lambda to dispose and recreate a runtime environment to pickup a change
39
+ // this approach is less flexible but more performant than reading the value of the environment variable at each invocation
40
+ var log = logger
41
+ log. logLevel = Lambda . env ( " LOG_LEVEL " ) . flatMap ( Logger . Level. init) ?? . info
36
42
self . logger = logger
37
43
}
38
44
You can’t perform that action at this time.
0 commit comments