Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile Releases Transform may end up trying duplicate work #283

Closed
ghost opened this issue Apr 22, 2020 · 2 comments
Closed

Compile Releases Transform may end up trying duplicate work #283

ghost opened this issue Apr 22, 2020 · 2 comments
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Apr 22, 2020

It makes a list of OCID's it needs to compile by crossing data in the source destination with data in destination one and looking for OCID's not processed yet.

We recently added something so that if an OCID can't be processed for whatever reason, it adds a collection note and moves on. #63 #279

But this means it may try and do work twice

  • Start collection 1
  • Make list of OCID's not yet processed
  • Try and process OCID 1 and fail, log collection note
  • Process ends before collection marked as finished
  • Start process again
  • Start collection 1
  • Make list of OCID's not yet processed
  • Try and process OCID 1 and fail, log collection note

We are saved a bit in that database.add_collection_note will not insert duplicate notes, so we don't end up with a lot of database entries. But we do waste machine time trying something we've already tried.

@jpmckinney
Copy link
Member

jpmckinney commented Apr 22, 2020

This problem will go away once we use queues, so I'm okay with closing this issue as the duplicate work has no ill effect besides being a tiny bit slower in the rare case of bad data.

@jpmckinney
Copy link
Member

See also discussion in #244

@jpmckinney jpmckinney added the bug Something isn't working label Apr 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant