pgreze
02/04/2021, 6:51 AMOutOfMemoryError: Java heap space
I’m facing.
I’m trying to download a file and write its content in a file like that:
val result = location.httpGet().response()
destination.writeBytes(result.third.get())
Is there some built-in helper in order to help avoiding memory issues?
thx in advance 🙏val response = location.httpDownload()
.fileDestination { _, _ -> destination }
.response()
check(response.second.statusCode == 200) { "Invalid download: $response" }
kittinunf
02/04/2021, 7:38 AMpgreze
02/04/2021, 7:54 AMkittinunf
02/04/2021, 8:43 AMpgreze
02/09/2021, 6:22 AM