From 0c46b958536fd4ead055209195c103465681064d Mon Sep 17 00:00:00 2001 From: James Gunn Date: Fri, 1 Dec 2023 11:58:45 +0000 Subject: [PATCH] Revert "Remove `for update` from state lookup (#768)" This reverts commit dff900d4633568346ea3ad98436de6691f030470. --- .../State/DbAuthenticationStateProvider.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotnet-authserver/src/TeacherIdentity.AuthServer/State/DbAuthenticationStateProvider.cs b/dotnet-authserver/src/TeacherIdentity.AuthServer/State/DbAuthenticationStateProvider.cs index 191bd0e5d..ee2637455 100644 --- a/dotnet-authserver/src/TeacherIdentity.AuthServer/State/DbAuthenticationStateProvider.cs +++ b/dotnet-authserver/src/TeacherIdentity.AuthServer/State/DbAuthenticationStateProvider.cs @@ -58,7 +58,7 @@ public DbAuthenticationStateProvider( using var suppressScope = SentryErrors.Suppress(IsPostgresSerializationError); var dbAuthState = await _dbContext.AuthenticationStates.FromSqlInterpolated( - $"select * from authentication_states where journey_id = {journeyId}") + $"select * from authentication_states where journey_id = {journeyId} for update") .SingleOrDefaultAsync(); if (dbAuthState is not null)