-
Notifications
You must be signed in to change notification settings - Fork 442
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
Move log writing operation to a background job #8548
Move log writing operation to a background job #8548
Conversation
So you create a DB entry to avoid creating a DB entry? |
|
a8cdad9
to
bdd9770
Compare
@@ -79,7 +78,7 @@ def preview_copy | |||
def copy | |||
authorize @staging_workflow | |||
|
|||
StagingProjectCopyJob.perform_later(@staging_workflow.project.name, params[:staging_project_project_name], params[:staging_project_copy_name], User.session!.id) | |||
StagingProjectCopyJob.perform_now(@staging_workflow.project.name, params[:staging_project_project_name], params[:staging_project_copy_name], User.session!.id) |
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.
That makes little sense, why do you change this?
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.
yes I was thinking about it too. Actually I wanted to go back to perform_later
, but I've got sidetracked by another issue. perform_later
is less intrusive. The logging has low priority and shouldn't block other jobs to execute..
bdd9770
to
5a6696d
Compare
5a6696d
to
f42f014
Compare
Move log writing operation to a background job.
Non-critical operations, like log writing, shouldn't influence in the user experience.