Retry store_lti_session_data
We need to store or update the LTI parameters. However, this operation is not atomic and multiple requests can interfere with our database operation. Therefore, we need to retry in case the record is not unique. Fixes CODEOCEAN-TC
This commit is contained in:
@ -225,6 +225,8 @@ module Lti
|
||||
@lti_parameters.save!
|
||||
|
||||
session[:external_user_id] = current_user.id
|
||||
rescue ActiveRecord::RecordNotUnique
|
||||
retry
|
||||
end
|
||||
|
||||
private :store_lti_session_data
|
||||
|
Reference in New Issue
Block a user