mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-10 09:40:44 +01:00
Merge pull request #16845 from JPVenson/backport/adaptLoggingForUserConcurrency
Update log for user session related concurrency update fails
This commit is contained in:
@@ -268,6 +268,11 @@ public class JellyfinDbContext(DbContextOptions<JellyfinDbContext> options, ILog
|
||||
}).ConfigureAwait(false);
|
||||
return result;
|
||||
}
|
||||
catch (DbUpdateConcurrencyException)
|
||||
{
|
||||
// a concurrency exception is supposed to be always handled by the invoker of the method, logging it here is only causing log bloat.
|
||||
throw;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
logger.LogError(e, "Error trying to save changes.");
|
||||
@@ -289,6 +294,11 @@ public class JellyfinDbContext(DbContextOptions<JellyfinDbContext> options, ILog
|
||||
});
|
||||
return result;
|
||||
}
|
||||
catch (DbUpdateConcurrencyException)
|
||||
{
|
||||
// a concurrency exception is supposed to be always handled by the invoker of the method, logging it here is only causing log bloat.
|
||||
throw;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
logger.LogError(e, "Error trying to save changes.");
|
||||
|
||||
Reference in New Issue
Block a user