From 3053e41b1528ef898cccd44e056e4d167619af6b Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Thu, 23 May 2024 11:45:38 +0200 Subject: fix: abort import of source on batch processing errors --- internal/importer/main.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'internal/importer/main.go') diff --git a/internal/importer/main.go b/internal/importer/main.go index 663e8eb..6f462c3 100644 --- a/internal/importer/main.go +++ b/internal/importer/main.go @@ -124,7 +124,12 @@ func Start( continue } - hadWarnings := process(ctx, indexer, processor, logger) + hadWarnings, err := process(ctx, indexer, processor, logger) + if err != nil { + logger.Error("failed to process source", "error", err) + + continue + } if hadWarnings { logger.Warn("importer succeeded, but with warnings/errors") -- cgit 1.4.1