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

90%: Queue bulk composite generation #55

Merged

Conversation

rsinger
Copy link
Member

@rsinger rsinger commented May 18, 2015

This refactors the createTables and createViews scripts to allow them to push the actual regeneration to the resque queue. You may also specify which queue you want these to go on, so as not to clog the regular process queue.

It also introduces a createSearchDocuments script which never existed in Tripod.

The major difference between these and how they work currently is that the current version loops over the CBDs and generates the composites serially. This version gives the option to loop over the CBDs and submits a job to generate the composite, so the actual generation can be scaled/stopped as needed without starting from the beginning to resume.

If you don't pass the -a/--async flag it works exactly as it does now.

-d --spec Only create for specified search document specs
-i --id Resource ID to regenerate search documents for
-a --async Generate table rows via queue
-q --queue Queue name to place jobs on (defaults to configured TRIPOD_APPLY_QUEUE value)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you specify an alternative queue, how do you know anything is listening to it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't - the purpose is you'd fire up a worker to listen for that queue to keep it from polluting/clogging the main queue

@malcyL
Copy link
Contributor

malcyL commented May 22, 2015

👍

rsinger added a commit that referenced this pull request May 22, 2015
@rsinger rsinger merged commit 5478314 into decouple-invalidation-from-save May 22, 2015
@rsinger rsinger deleted the queue-bulk-composite-generation branch May 22, 2015 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants