From 7205ee508f1ef3b90c650c5dc88e393a39369171 Mon Sep 17 00:00:00 2001 From: KirillPamPam Date: Mon, 23 Feb 2026 13:37:17 +0400 Subject: [PATCH] Set req timeout via env --- src/main/kotlin/io/emeraldpay/dshackle/Starter.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/kotlin/io/emeraldpay/dshackle/Starter.kt b/src/main/kotlin/io/emeraldpay/dshackle/Starter.kt index f1d00c8a..53ac7709 100644 --- a/src/main/kotlin/io/emeraldpay/dshackle/Starter.kt +++ b/src/main/kotlin/io/emeraldpay/dshackle/Starter.kt @@ -38,6 +38,9 @@ open class Starter private val log = LoggerFactory.getLogger(Starter::class.java) fun main(args: Array) { + System.getenv()["HTTP_REQ_TIMEOUT"] + ?.let { System.setProperty("sun.net.httpserver.maxReqTime", it) } + ContextRegistry.getInstance().registerThreadLocalAccessor(Slf4jThreadLocalAccessor()) Hooks.enableAutomaticContextPropagation() OpenSsl.ensureAvailability()