mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-09-07 17:15:56 +00:00
return error in Batch.doImport if there is one
swallowing this error was a mistake... caller would not know that ingest failed and might incorrectly report success upstream (e.g. committing offsets to Kafka)
This commit is contained in:
parent
dc20f8c689
commit
62971f55dd
1 changed files with 1 additions and 3 deletions
|
|
@ -700,9 +700,7 @@ func (b *Batch) Import() error {
|
|||
// import int data.
|
||||
err = b.doImport(frags, clearFrags)
|
||||
if err != nil {
|
||||
// doImport actually imports the ingested data. An error here, means an error with the value that is trying to be ingested.
|
||||
// We log the error, so we can continue ingesting. Returning would stop the ingest.
|
||||
b.log.Printf("error importing batch: %v", err)
|
||||
return errors.Wrap(err, "doing import")
|
||||
}
|
||||
b.log.Printf("importing fragments took %v", time.Since(makeTime))
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue