ktor-client-logging has problems handling large response content
See original GitHub issueKtor Version
1.0.1
Ktor Engine Used(client or server and name)
Client
JVM Version, Operating System and Relevant Context
Android
Feedback
Doing a request, if the request creates an error (Code 500) at the backend and the backend response is a large (9000+ character) error content, I would like to be able to see this in the log but currently this does not seem to be supported because no content what so ever is printed out.
Currently it will get stuck at:
INFO io.ktor.client.HttpClient - BODY Content-Type: application/json; charset=utf-8
INFO io.ktor.client.HttpClient - BODY START
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Logging - Ktor
Ktor client provides the capability to log HTTP calls using the Logging plugin. This plugin provides different logger types for different ...
Read more >Parsing an error body in a ktor HTTPClient - Stack Overflow
My query here is I am not able to access the response error body in either validateResponse or handleResponseException . Is there a...
Read more >Ktor - JetBrains YouTrack
KTOR -5327 Client fails to parse response without Content-Length, Connection headers and chunked transfer encoding. 1. Bug. Server. 2.2.1. No plugin version.
Read more >Table of Contents - Micronaut Documentation
Micronaut now supports the latest GraalVM 22.0.0.2 release. Environment Endpoint. A new API EnvironmentEndpointFilter has been created to allow applications to ...
Read more >How to Build an Android Wellness App with the Ktor ... - Perpetio
Instead, we have something more fascinating to show — the Ktor Client dependencies ... implementation "io.ktor:ktor-client-logging:$ktor_version" // Ktor ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Added:
to the dependency which solved the above issue. Now I’m still stuck at:
But i’m not sure if this is an error on my side while implementing ktor or not, i’ve made a wrapper around ktor-client which ends up a builder looking like this(this is commonMain code):
Updated ktor client to 1.1.1 and it now get this instead: W/System.err: SLF4J: Failed to load class “org.slf4j.impl.StaticLoggerBinder”.
This with using: