How do I clean up resources after completing a cal...
# ktor
m
How do I clean up resources after completing a call without closing the entire
HttpClient
?
HttpResponse.close()
is deprecated. With CIO I get
BindException: Can't assign requested address
under high load which is probably due to some (temporary?) resource leak.
e
Hey, the
HttpResponse
is in memory, so you don't need cleanup any resources.
Could you describe what kind of leak do you have?
m
This test randomly either freezes or throws the `BindException`: https://gist.github.com/fluidsonic/510f0df9c77d70d72793f92cced04ab2 Reported: https://youtrack.jetbrains.com/issue/KTOR-1126
e
Thanks!, We will take a look
🙏 1
m
While you’re at it 😄 Apache & Jetty engines are highly unstable too, probably for the same reason. https://youtrack.jetbrains.com/issue/KTOR-717 https://youtrack.jetbrains.com/issue/KTOR-1120