-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add report emails to preservation workflow
Why these changes are being introduced: We found a bug in the preservation workflow last month that we might have identified sooner if the preservation submission job triggered a report email. Relevant ticket(s): https://mitlibraries.atlassian.net/browse/ETD-651 How this addresses that need: * Removes the Preservation Submission Prep Job * Updates the Preservation Submission Job to accept an array of theses * Adds a preservation results email to the Report Mailer that is enqueued on completion of the Preservation Submission Job * Updates the preservation rake task to convert the input thesis into an array, so it will continue to work Side effects of this change: We not sure why we implemented the 'prep' job pattern: passing in an array of theses so the actual job takes a single thesis as a parameter. There is some risk in removing this job, since we don't remember why it exists in the first place.
- Loading branch information
Showing
10 changed files
with
88 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
app/views/report_mailer/preservation_results_email.html.erb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<p>Hello,</p> | ||
|
||
<p>Below is a report of the Archivematica preservation submission job.</p> | ||
|
||
<p>Summary of results:</p> | ||
|
||
<ul> | ||
<li>Total theses queued for preservation: <%= @results[:total] %></li> | ||
<li>Total theses sent to preservation: <%= @results[:processed] %></li> | ||
<li>Errors found: <%= @results[:errors].count %></li> | ||
</ul> | ||
|
||
<% if @results[:errors].any? %> | ||
<p>The following errors require processor attention:</p> | ||
|
||
<ul> | ||
<% @results[:errors].each do |e| %> | ||
<li><%= e %></li> | ||
<% end %> | ||
</ul> | ||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters