[#2180] Add separate notification for (slow) PJ listing
This commit is contained in:
parent
64c45c4789
commit
7b18c51483
1 changed files with 3 additions and 2 deletions
|
@ -67,12 +67,13 @@ namespace :'2018_12_03_finish_piece_jointe_transfer' do
|
||||||
# This task ports them to the new storage after the switch, while being careful not to
|
# This task ports them to the new storage after the switch, while being careful not to
|
||||||
# overwrite attachments that may have changed in the new storage after the switch.
|
# overwrite attachments that may have changed in the new storage after the switch.
|
||||||
def refresh_outdated_files
|
def refresh_outdated_files
|
||||||
rake_puts "Refresh outdated attachments"
|
|
||||||
|
|
||||||
refreshed_keys = []
|
refreshed_keys = []
|
||||||
missing_keys = []
|
missing_keys = []
|
||||||
old_pj_adapter.session do |old_pjs|
|
old_pj_adapter.session do |old_pjs|
|
||||||
|
rake_puts "List old PJs"
|
||||||
keys = old_pjs.list_prefixed('')
|
keys = old_pjs.list_prefixed('')
|
||||||
|
|
||||||
|
rake_puts "Refresh outdated attachments"
|
||||||
progress = ProgressReport.new(keys.count)
|
progress = ProgressReport.new(keys.count)
|
||||||
keys.each do |key|
|
keys.each do |key|
|
||||||
new_pj_metadata = new_pjs.files.head(key)
|
new_pj_metadata = new_pjs.files.head(key)
|
||||||
|
|
Loading…
Add table
Reference in a new issue