diff options
| author | cvium <clausvium@gmail.com> | 2022-10-21 11:55:32 +0200 |
|---|---|---|
| committer | cvium <clausvium@gmail.com> | 2022-10-21 11:55:32 +0200 |
| commit | b836fe96857de9e39d9b565b1f57a151a82e401d (patch) | |
| tree | c49622deedb94fa93ca95aea3199953ce0f4e629 /Jellyfin.Server/CoreAppHost.cs | |
| parent | 509c6ec24ca35b2e16561808792cd581c5f9d8fc (diff) | |
remove JellyfinDbProvider and add second level caching
Diffstat (limited to 'Jellyfin.Server/CoreAppHost.cs')
| -rw-r--r-- | Jellyfin.Server/CoreAppHost.cs | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/Jellyfin.Server/CoreAppHost.cs b/Jellyfin.Server/CoreAppHost.cs index 984711dc2..002193baf 100644 --- a/Jellyfin.Server/CoreAppHost.cs +++ b/Jellyfin.Server/CoreAppHost.cs @@ -1,6 +1,5 @@ using System; using System.Collections.Generic; -using System.IO; using System.Reflection; using Emby.Drawing; using Emby.Server.Implementations; @@ -71,19 +70,13 @@ namespace Jellyfin.Server Logger.LogWarning("Skia not available. Will fallback to {ImageEncoder}.", nameof(NullImageEncoder)); } - serviceCollection.AddDbContextPool<JellyfinDb>( - options => options - .UseLoggerFactory(LoggerFactory) - .UseSqlite($"Filename={Path.Combine(ApplicationPaths.DataPath, "jellyfin.db")}")); - serviceCollection.AddEventServices(); serviceCollection.AddSingleton<IBaseItemManager, BaseItemManager>(); serviceCollection.AddSingleton<IEventManager, EventManager>(); - serviceCollection.AddSingleton<JellyfinDbProvider>(); serviceCollection.AddSingleton<IActivityManager, ActivityManager>(); serviceCollection.AddSingleton<IUserManager, UserManager>(); - serviceCollection.AddSingleton<IDisplayPreferencesManager, DisplayPreferencesManager>(); + serviceCollection.AddScoped<IDisplayPreferencesManager, DisplayPreferencesManager>(); serviceCollection.AddSingleton<IDeviceManager, DeviceManager>(); // TODO search the assemblies instead of adding them manually? |
