Class: HCA::EzrSubmissionJob
- Inherits:
-
Object
- Object
- HCA::EzrSubmissionJob
show all
- Includes:
- SentryLogging, Sidekiq::Job
- Defined in:
- app/sidekiq/hca/ezr_submission_job.rb
Constant Summary
collapse
- VALIDATION_ERROR =
HCA::SOAPParser::ValidationError
Class Method Summary
collapse
Instance Method Summary
collapse
#log_exception_to_sentry, #log_message_to_sentry, #non_nil_hash?, #normalize_level, #rails_logger
Class Method Details
22
23
24
|
# File 'app/sidekiq/hca/ezr_submission_job.rb', line 22
def self.decrypt_form(encrypted_form)
JSON.parse(HealthCareApplication::LOCKBOX.decrypt(encrypted_form))
end
|
.log_submission_failure(parsed_form) ⇒ Object
Instance Method Details
30
31
32
33
34
35
36
37
38
39
|
# File 'app/sidekiq/hca/ezr_submission_job.rb', line 30
def perform(encrypted_form, user_identifier)
parsed_form = self.class.decrypt_form(encrypted_form)
Form1010Ezr::Service.new(user_identifier).submit_sync(parsed_form)
rescue VALIDATION_ERROR => e
self.class.log_submission_failure(parsed_form)
log_exception_to_sentry(e)
rescue
log_retry
raise
end
|