/// <summary> /// Performs the configuration and registers it /// </summary> /// <param name="configurer">Reference to the configuration for fluent syntax</param> /// <param name="storageClient">Reference to the single instance of Google StorageClient</param> /// <param name="options">Options to configure the subscription storage</param> static void Configure(StandardConfigurer <ISubscriptionStorage> configurer, StorageClient storageClient, GoogleCloudStorageSubscriptionOptions options) { configurer.Register(c => { var rebusLoggerFactory = c.Get <IRebusLoggerFactory>(); return(new GoogleCloudStorageSubscriptionsStorage(storageClient, rebusLoggerFactory, options)); }); }
/// <summary> /// Configures the storage of subscriptions in Google Cloud Storage /// </summary> /// <param name="configurer">Reference to the configuration for fluent syntax</param> /// <param name="storageClient">Reference to the single instance of Google StorageClient</param> /// <param name="options">Options to configure the subscription storage</param> public static void StoreInGoogleCloudStorage(this StandardConfigurer <ISubscriptionStorage> configurer, StorageClient storageClient, GoogleCloudStorageSubscriptionOptions options) { if (configurer == null) { throw new ArgumentNullException(nameof(configurer)); } if (storageClient == null) { throw new ArgumentNullException(nameof(storageClient)); } if (options == null) { throw new ArgumentNullException(nameof(options)); } Configure(configurer, storageClient, options); }