This is an automated email from the ASF dual-hosted git repository.

klesh pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git


The following commit(s) were added to refs/heads/main by this push:
     new 98cb04b2d fix: finalizable-entity collector issues in full sync mode 
(#6285)
98cb04b2d is described below

commit 98cb04b2d402872840ac3fccb39e4f431cbf7a40
Author: abeizn <[email protected]>
AuthorDate: Thu Oct 19 05:04:51 2023 -0500

    fix: finalizable-entity collector issues in full sync mode (#6285)
    
    * fix: finalizable-entity collector issues in full sync mode
    
    * fix: finalizable entity collector
---
 backend/helpers/pluginhelper/api/api_collector_with_state.go | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/backend/helpers/pluginhelper/api/api_collector_with_state.go 
b/backend/helpers/pluginhelper/api/api_collector_with_state.go
index c4b22f110..fdbdea013 100644
--- a/backend/helpers/pluginhelper/api/api_collector_with_state.go
+++ b/backend/helpers/pluginhelper/api/api_collector_with_state.go
@@ -183,6 +183,7 @@ func NewStatefulApiCollectorForFinalizableEntity(args 
FinalizableApiCollectorArg
 
        createdAfter := manager.Since
        isIncremental := manager.IsIncremental
+
        // step 1: create a collector to collect newly added records
        err = manager.InitCollector(ApiCollectorArgs{
                ApiClient: args.ApiClient,
@@ -246,7 +247,8 @@ func NewStatefulApiCollectorForFinalizableEntity(args 
FinalizableApiCollectorArg
                return nil, err
        }
 
-       if args.CollectUnfinishedDetails == nil {
+       syncPolicy := args.Ctx.TaskContext().SyncPolicy()
+       if args.CollectUnfinishedDetails == nil || (syncPolicy != nil && 
syncPolicy.FullSync) {
                return manager, nil
        }
 

Reply via email to