File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
lambda-runtime/src/commonMain/kotlin/io/github/trueangle/knative/lambda/runtime Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,7 @@ object LambdaRuntime {
63
63
64
64
with (Log ) {
65
65
setContext(context)
66
+
66
67
trace(event)
67
68
trace(context)
68
69
}
@@ -83,6 +84,7 @@ object LambdaRuntime {
83
84
when (e) {
84
85
is NonRecoverableStateException -> {
85
86
Log .fatal(e)
87
+
86
88
exitProcess(1 )
87
89
}
88
90
Original file line number Diff line number Diff line change @@ -24,7 +24,6 @@ import io.ktor.http.contentType
24
24
import io.ktor.util.reflect.TypeInfo
25
25
import kotlinx.serialization.json.Json
26
26
import kotlin.time.Duration.Companion.minutes
27
- import kotlin.time.TimeSource
28
27
import io.ktor.http.ContentType.Application.Json as ContentTypeJson
29
28
30
29
@PublishedApi
@@ -34,9 +33,8 @@ internal class LambdaClient(private val httpClient: HttpClient) {
34
33
suspend fun <T > retrieveNextEvent (bodyType : TypeInfo ): Pair <T , Context > {
35
34
val response = httpClient.get {
36
35
url(" ${invokeUrl} /invocation/next" )
37
- timeout {
38
- requestTimeoutMillis = 60 * 1000 * 30 // todo
39
- }
36
+
37
+ timeout { requestTimeoutMillis = 15 .minutes.inWholeMilliseconds }
40
38
}
41
39
val context = contextFromResponseHeaders(response)
42
40
val body = try {
@@ -72,7 +70,7 @@ internal class LambdaClient(private val httpClient: HttpClient) {
72
70
url(" ${invokeUrl} /invocation/${event.awsRequestId} /response" )
73
71
74
72
timeout {
75
- requestTimeoutMillis = 30 .minutes.inWholeMilliseconds // todo
73
+ requestTimeoutMillis = 15 .minutes.inWholeMilliseconds
76
74
}
77
75
78
76
headers {
You can’t perform that action at this time.
0 commit comments