Skip to content

Commit

Permalink
Bulk Load CDK: Fix transient failure due to multiple channel closures
Browse files Browse the repository at this point in the history
  • Loading branch information
johnny-schmidt committed Oct 20, 2024
1 parent 7b70a70 commit 09e6b1f
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,8 @@ class S3MultipartUpload<T : OutputStream>(

inner class UploadStream : OutputStream() {
override fun close() = runBlocking {
workQueue.send {
if (closeOnce.setOnce()) {
workQueue.close()
}
if (closeOnce.setOnce()) {
workQueue.send { workQueue.close() }
}
}

Expand Down

0 comments on commit 09e6b1f

Please sign in to comment.