From 3de2ec32a6ae5674c308a6edee985dd170fcfcba Mon Sep 17 00:00:00 2001 From: ypc-faros <99700024+ypc-faros@users.noreply.github.com> Date: Mon, 9 Dec 2024 12:32:23 -0500 Subject: [PATCH] The backfill check should take more precedence when determining whether to reset data (#1846) --- .../airbyte-faros-destination/src/destination.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/destinations/airbyte-faros-destination/src/destination.ts b/destinations/airbyte-faros-destination/src/destination.ts index bb85e6a06..fe8951c8e 100644 --- a/destinations/airbyte-faros-destination/src/destination.ts +++ b/destinations/airbyte-faros-destination/src/destination.ts @@ -997,6 +997,12 @@ export class FarosDestination extends AirbyteDestination { isFarosSource, sourceSucceeded, } = syncInfo; + if (isBackfillSync) { + this.logger.info( + 'Running a backfill sync. Skipping reset of non-incremental models.' + ); + return false; + } if (streamStatusReceived) { if (syncErrors.dst.length) { this.logger.warn( @@ -1026,12 +1032,6 @@ export class FarosDestination extends AirbyteDestination { this.logger.info('Running a reset sync. Resetting all models.'); return true; } - if (isBackfillSync) { - this.logger.info( - 'Running a backfill sync. Skipping reset of non-incremental models.' - ); - return false; - } if (sourceSucceeded) { this.logger.info('Source succeeded. Resetting non-incremental models.'); return true;