From 84df778a2db8821c6650acbd81b5b84f09040b7e Mon Sep 17 00:00:00 2001 From: Roman Lomonosov Date: Wed, 21 Mar 2018 19:17:49 +0000 Subject: [PATCH] bugfix: series table stops uploading into clickhouse after error --- uploader/cached.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/uploader/cached.go b/uploader/cached.go index 3b482fd4..e0e64c91 100644 --- a/uploader/cached.go +++ b/uploader/cached.go @@ -57,10 +57,14 @@ func (u *cached) upload(exit chan struct{}, logger *zap.Logger, filename string) uploadResult := make(chan error, 1) u.Go(func(exit chan struct{}) { - uploadResult <- u.insertRowBinary( + err := u.insertRowBinary( u.insertQuery, pipeReader, ) + uploadResult <- err + if err != nil { + pipeReader.CloseWithError(err) + } }) newSeries, err := u.parser(filename, writer)