"Due to the growing number of 7959F1 files, our temporary files with the same name can cause conflicts. This could lead to issues if two users try to save a file with the same 7959F1 name simultaneously."
If the files are named correctly, we won't see this error:Error: An error occurred while verifying stamp: No such file or directory @ rb_file_s_rename which is caused by conflicting naming, e.g. tmp/vha_10_7959f_1-stamped.pdf or tmp/vha_10_7959f_1.pdf
Old AC: Each application 7959F1 file unique name, like use a SecureRandom.hex. example:
generated_form_path = Rails.root.join("tmp/#{name}-#{SecureRandom.hex}-tmp.pdf").to_s
stamped_template_path = Rails.root.join("tmp/#{name}-#{SecureRandom.hex}-stamped.pdf").to_s
New AC:
All temporary files must be uniquely named.
Need unit test to ensure that the output file for s3 is named correctly:
It should not be this format:tmp/vha_10_7959f_1-cf1b6e07204447096d9bf37837c61df7.pdf
or thistmp/vha_10_7959f_1-stamped.pdfortmp/vha_10_7959f_1.pdf
Correct format is: tmp/0099687f-7e9c-45a9-8865-ac67f0d7ef31_vha_10_7959f_1.pdf for PEGA to process the claims
"Due to the growing number of 7959F1 files, our temporary files with the same name can cause conflicts. This could lead to issues if two users try to save a file with the same 7959F1 name simultaneously." If the files are named correctly, we won't see this error:
Error: An error occurred while verifying stamp: No such file or directory @ rb_file_s_rename
which is caused by conflicting naming, e.g. tmp/vha_10_7959f_1-stamped.pdf or tmp/vha_10_7959f_1.pdfOld AC: Each application 7959F1 file unique name, like use a SecureRandom.hex. example: generated_form_path = Rails.root.join("tmp/#{name}-#{SecureRandom.hex}-tmp.pdf").to_s stamped_template_path = Rails.root.join("tmp/#{name}-#{SecureRandom.hex}-stamped.pdf").to_s
New AC: All temporary files must be uniquely named. Need unit test to ensure that the output file for s3 is named correctly: It should not be this format:
tmp/vha_10_7959f_1-cf1b6e07204447096d9bf37837c61df7.pdf
or thistmp/vha_10_7959f_1-stamped.pdf
ortmp/vha_10_7959f_1.pdf
Correct format is: tmp/0099687f-7e9c-45a9-8865-ac67f0d7ef31_vha_10_7959f_1.pdf for PEGA to process the claims