You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently I see that some calls of metadata workers can even not create sync process in DB. For example SAW sync:
defperformresult=synchronisation.new_context{importer.fetch_countries}ifresult.success?countries=result.valueelsemessage="Failed to perform the `#fetch_countries` operation"announce_error(message,result)returnend
...
My position is that every run of worker should leave something after it (for example successful/unsuccessful sync_process record in DB). So I wanted to make it mandatory to call sync.finish! for all wokers, but we also shouldn't forget to call skip_purge in some error cases, otherwise we can purge all the properties((((
Here how I would fix the SAW's worker:
defperformresult=synchronisation.new_context{importer.fetch_countries}ifresult.success?countries=result.valueelsemessage="Failed to perform the `#fetch_countries` operation"announce_error(message,result)synchronisation.skip_purge!synchronisation.finish!returnend
...
Please let me know what do you think about this thought.
The text was updated successfully, but these errors were encountered:
It's still depends on each supplier implementation, some of them
download all properties and sync them one by one
another
download properties group by group (and we should skip_purge if one group fails)
I don't have idea how to create shared spec for all the suppliers.
But I have a suggestion how we can prevent purging all the properties: before purge we should check if start method was called at least once, if no - don't run the purge.
Currently I see that some calls of metadata workers can even not create sync process in DB. For example SAW sync:
My position is that every run of worker should leave something after it (for example successful/unsuccessful sync_process record in DB). So I wanted to make it mandatory to call
sync.finish!
for all wokers, but we also shouldn't forget to callskip_purge
in some error cases, otherwise we can purge all the properties((((Here how I would fix the SAW's worker:
Please let me know what do you think about this thought.
The text was updated successfully, but these errors were encountered: