Hi! What we have in the changelog for KTor 1.6.0 <...
# ktor
r
Hi! What we have in the changelog for KTor 1.6.0 https://ktor.io/changelog/1.6/ regarding Client upload/download progress observer/handler/interceptor (https://youtrack.jetbrains.com/issue/KTOR-400)
I assume currently it exists but I don't know how to do it, can somebody help me please 🙂 ?
Also the following doesn't work (unresolved reference eventListener)
Copy code
val retMessage =  httpClient.request<Message> {
            eventListener = { event ->
                println("${event.bytesSent / event.bytesTotal}% uploaded")
            }
        }
So is there any support for progress observer introduced in 1.6.0 or not?
r
Copy code
val response: HttpResponse = client.get("<http://localhost:8080/products>") {
    onDownload { bytesSendTotal: Long, contentLength: Long -> TODO("update UI") }
    onUpload { bytesSendTotal: Long, contentLength: Long -> TODO("update UI") }
}
is the API you are looking for
🙏 1