Hi there. Recently i built a load-testing tool for...
# ktor
v
Hi there. Recently i built a load-testing tool for our websocket service based on ktor http client (CIO). But for some reason i only can reliably run load against local instance of service. When i'm pointing tool at remote (staging) instance program start to crash with
java.lang.StackOverflowError
with some enormous stacktraces involving coroutines resume and ktor.util.pipeline.SuspendFunctionGun.resumeRootWith. The only difference between local and remote instances is enabled tls on remote and latency. Snippet:
Copy code
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
        at io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(PipelineContext.kt:219)
        at io.ktor.util.pipeline.SuspendFunctionGun.access$resumeRootWith(PipelineContext.kt:67)
        at io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(PipelineContext.kt:118)
        at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
Full traceback of one fail: https://pastebin.com/dVi5R5ty ktor 1.3.1, kotlin 1.4.10, kotlinx.coroutines 1.3.9 How do i fix or debug this?