Class JobFlowConfigurationBuilderExtensions
- Namespace
- JobFlow.Core.Configuration
- Assembly
- JobFlow.Core.dll
public static class JobFlowConfigurationBuilderExtensions
- Inheritance
-
JobFlowConfigurationBuilderExtensions
Methods
AddConfiguration(JobFlowConfigurationBuilder, IConfiguration, IConfigurationSection)
Adds configured options to the configuration builder.
public static BaseJobFlowConfigurationBuilder AddConfiguration(this JobFlowConfigurationBuilder config, IConfiguration applicationConfiguration, IConfigurationSection configuration)
Parameters
config
JobFlowConfigurationBuilderapplicationConfiguration
IConfigurationconfiguration
IConfigurationSectionIConfiguration instance to read the options from.
Returns
AddConfiguration(JobFlowConfigurationBuilder, IConfiguration, string)
public static BaseJobFlowConfigurationBuilder AddConfiguration(this JobFlowConfigurationBuilder config, IConfiguration applicationConfiguration, string sectionName = "JobFlow")
Parameters
config
JobFlowConfigurationBuilderapplicationConfiguration
IConfigurationsectionName
string
Returns
AddCore(JobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddCore(this JobFlowConfigurationBuilder config)
Parameters
config
JobFlowConfigurationBuilder
Returns
AddDependencyAssembly(BaseJobFlowConfigurationBuilder, Assembly)
Adds a dependency assembly to be scanned by the TypeScanner.
public static BaseJobFlowConfigurationBuilder AddDependencyAssembly(this BaseJobFlowConfigurationBuilder config, Assembly assembly)
Parameters
config
BaseJobFlowConfigurationBuilderassembly
Assembly
Returns
Remarks
A dependency assembly can contain items that include:
- Dependency injection services
- Document model classes
- Business rules
AddDependencyAssembly<T>(BaseJobFlowConfigurationBuilder)
Adds a dependency assembly to be scanned by the TypeScanner.
public static BaseJobFlowConfigurationBuilder AddDependencyAssembly<T>(this BaseJobFlowConfigurationBuilder config)
Parameters
Returns
Type Parameters
T
A type contained within the Assembly to scan.
Remarks
A dependency assembly can contain items that include:
- Dependency injection services
- Document model classes
- Business rules
AddDiskStorage(JobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddDiskStorage(this JobFlowConfigurationBuilder configurationBuilder)
Parameters
configurationBuilder
JobFlowConfigurationBuilder
Returns
AddDocumentStorage(BaseJobFlowConfigurationBuilder)
Add document storage support.
public static BaseJobFlowConfigurationBuilder AddDocumentStorage(this BaseJobFlowConfigurationBuilder config)
Parameters
Returns
Remarks
This is called by AddJobFlowServer.
AddFactory<TService>(BaseJobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddFactory<TService>(this BaseJobFlowConfigurationBuilder config)
Parameters
Returns
Type Parameters
TService
AddFactory<TService, TAttr>(BaseJobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddFactory<TService, TAttr>(this BaseJobFlowConfigurationBuilder config) where TAttr : ServiceKeyAttribute
Parameters
Returns
Type Parameters
TService
TAttr
AddFactory<TService, TAttr, TConfig>(BaseJobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddFactory<TService, TAttr, TConfig>(this BaseJobFlowConfigurationBuilder config) where TAttr : ServiceKeyAttribute where TConfig : KeyedServiceConfiguration<TAttr, TService>
Parameters
Returns
Type Parameters
TService
TAttr
TConfig
AddFactory<TService, TAttr, TConfig, TFactory>(BaseJobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddFactory<TService, TAttr, TConfig, TFactory>(this BaseJobFlowConfigurationBuilder config) where TAttr : ServiceKeyAttribute where TConfig : KeyedServiceConfiguration<TAttr, TService> where TFactory : KeyedServiceFactory<TConfig, TAttr, TService>
Parameters
Returns
Type Parameters
TService
TAttr
TConfig
TFactory
AddInMemoryStorage(JobFlowConfigurationBuilder)
public static BaseJobFlowConfigurationBuilder AddInMemoryStorage(this JobFlowConfigurationBuilder configurationBuilder)
Parameters
configurationBuilder
JobFlowConfigurationBuilder
Returns
AddJobDispatching(JobFlowConfigurationBuilder)
public static JobFlowConfigurationBuilder AddJobDispatching(this JobFlowConfigurationBuilder config)
Parameters
config
JobFlowConfigurationBuilder
Returns
AddJobFlowClient(JobFlowConfigurationBuilder)
Adds the base JobFlow configuration, including all required services, needed to run a worker.
public static JobFlowConfigurationBuilder AddJobFlowClient(this JobFlowConfigurationBuilder config)
Parameters
config
JobFlowConfigurationBuilder
Returns
Remarks
This can be used to set up a JobFlow worker instance. It does not add thing like document storage support or the business rule engine.
AddJobFlowClient(IServiceCollection, Action<JobFlowConfigurationBuilder>)
Adds the base JobFlow configuration, including all required services, needed to run a worker.
public static IServiceCollection AddJobFlowClient(this IServiceCollection services, Action<JobFlowConfigurationBuilder> configure)
Parameters
services
IServiceCollectionconfigure
Action<JobFlowConfigurationBuilder>Allows for additional customization of the configuration.
Returns
Remarks
This can be used to set up a JobFlow worker instance. It does not add thing like document storage support or the business rule engine.
AddJobFlowConfiguration(IServiceCollection, Action<JobFlowConfigurationBuilder>)
Adds an empty JobFlow configuration to the service collection. Use AddJobFlowServer to add a base configuration instead.
public static IServiceCollection AddJobFlowConfiguration(this IServiceCollection services, Action<JobFlowConfigurationBuilder> configure)
Parameters
services
IServiceCollectionconfigure
Action<JobFlowConfigurationBuilder>
Returns
AddJobFlowDbContext(JobFlowConfigurationBuilder, Action<DbContextOptionsBuilder>)
public static JobFlowConfigurationBuilder AddJobFlowDbContext(this JobFlowConfigurationBuilder services, Action<DbContextOptionsBuilder> optionsBuilder)
Parameters
services
JobFlowConfigurationBuilderoptionsBuilder
Action<DbContextOptionsBuilder>
Returns
AddJobFlowServer(IServiceCollection, Action<JobFlowConfigurationBuilder>)
Adds the base JobFlow configuration, including all required services, needed to run server functionality.
public static IServiceCollection AddJobFlowServer(this IServiceCollection services, Action<JobFlowConfigurationBuilder> configure)
Parameters
services
IServiceCollectionconfigure
Action<JobFlowConfigurationBuilder>
Returns
AddTransports(BaseJobFlowConfigurationBuilder)
Add Transport support.
public static BaseJobFlowConfigurationBuilder AddTransports(this BaseJobFlowConfigurationBuilder config)
Parameters
Returns
Remarks
This is called by both AddJobFlowWorker and AddJobFlowServer.
GlobalOptions(JobFlowConfigurationBuilder, Action<GlobalOptions>)
Set the JobFlow global options.
public static JobFlowConfigurationBuilder GlobalOptions(this JobFlowConfigurationBuilder config, Action<GlobalOptions> configure)
Parameters
config
JobFlowConfigurationBuilderconfigure
Action<GlobalOptions>
Returns
UseJobsContextMigrations(IServiceProvider)
Attempts to use automatic code migrations to update the JobFlow relational database.
public static void UseJobsContextMigrations(this IServiceProvider services)
Parameters
services
IServiceProvider
Remarks
This shouldn't be used in a production environment.