-
Notifications
You must be signed in to change notification settings - Fork 49
Expand file tree
/
Copy pathBasePersistence.cs
More file actions
38 lines (36 loc) · 2.23 KB
/
BasePersistence.cs
File metadata and controls
38 lines (36 loc) · 2.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
namespace ServiceControl.Persistence.Sql.Core.Abstractions;
using Microsoft.Extensions.DependencyInjection;
using ServiceControl.Persistence;
using ServiceControl.Persistence.MessageRedirects;
using ServiceControl.Persistence.UnitOfWork;
using Implementation;
using Implementation.UnitOfWork;
using Particular.LicensingComponent.Persistence;
public abstract class BasePersistence
{
protected static void RegisterDataStores(IServiceCollection services)
{
services.AddSingleton<MinimumRequiredStorageState>();
services.AddSingleton<ITrialLicenseDataProvider, TrialLicenseDataProvider>();
services.AddSingleton<IEndpointSettingsStore, EndpointSettingsStore>();
services.AddSingleton<IEventLogDataStore, EventLogDataStore>();
services.AddSingleton<IMessageRedirectsDataStore, MessageRedirectsDataStore>();
services.AddSingleton<IServiceControlSubscriptionStorage, ServiceControlSubscriptionStorage>();
services.AddSingleton<IQueueAddressStore, QueueAddressStore>();
services.AddSingleton<IMonitoringDataStore, MonitoringDataStore>();
services.AddSingleton<ICustomChecksDataStore, CustomChecksDataStore>();
services.AddSingleton<Operations.BodyStorage.IBodyStorage, BodyStorage>();
services.AddSingleton<IRetryHistoryDataStore, RetryHistoryDataStore>();
services.AddSingleton<IFailedErrorImportDataStore, FailedErrorImportDataStore>();
services.AddSingleton<IExternalIntegrationRequestsDataStore, ExternalIntegrationRequestsDataStore>();
services.AddSingleton<IFailedMessageViewIndexNotifications, FailedMessageViewIndexNotifications>();
services.AddSingleton<Recoverability.IArchiveMessages, ArchiveMessages>();
services.AddSingleton<IGroupsDataStore, GroupsDataStore>();
services.AddSingleton<IRetryDocumentDataStore, RetryDocumentDataStore>();
services.AddSingleton<IRetryBatchesDataStore, RetryBatchesDataStore>();
services.AddSingleton<IIngestionUnitOfWorkFactory, IngestionUnitOfWorkFactory>();
services.AddSingleton<IErrorMessageDataStore, ErrorMessageDataStore>();
services.AddSingleton<ILicensingDataStore, LicensingDataStore>();
services.AddSingleton<FileSystemBodyStorageHelper>();
}
}