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
Handle virtual object creation in a background job #422
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR message says you updated openapi.json, but I don't see that in the changed files.
53230c0
to
ce48348
Compare
@jcoyne 💬
Included now. |
23991be
to
8699868
Compare
Connects to #336 This makes it possible to reliably stash information about background jobs in a persistent store, which will be used to run virtual object creation in the background. Includes `factory_bot_rails` as a dependency which will make it easier to spin up fixture-like factories when testing with database entities later.
Connects to #336 The model holds any output from the job, an HTTP status code, and a processing status.
Connects to #336 This allows us to test database-backed entities, specifically BackgroundJobResults, more efficently.
Connects to #336 And use the new job from the CreateVirtualObjectsController. In the job, record progress and results in the application database.
8699868
to
bbed3cc
Compare
class CreateBackgroundJobResults < ActiveRecord::Migration[5.2] | ||
def up | ||
execute <<-SQL | ||
CREATE TYPE background_job_result_status AS ENUM ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! We should port this to workflow-service.
bbed3cc
to
34600a2
Compare
…l_objects endpoints
34600a2
to
d856d98
Compare
Connects to #336
Deployment blocked by sul-dlss/puppet#4470factory_bot_rails
as a dependency which will make it easier to spinup fixture-like factories when testing with database entities later.
BackgroundJobResults
.CreateVirtualObjectsController
. In the job, record progress and results in the application databaseWhy was this change made?
To be able to process large batches of virtual objects outside of the request/response cycle.
Was the API documentation (openapi.json) updated?
Yes.