File tree Expand file tree Collapse file tree 3 files changed +30
-0
lines changed
src/EventStore.Plugins/Subsystems Expand file tree Collapse file tree 3 files changed +30
-0
lines changed Original file line number Diff line number Diff line change
1
+ using System . Collections . Generic ;
2
+ using System . Threading . Tasks ;
3
+ using Microsoft . AspNetCore . Builder ;
4
+ using Microsoft . Extensions . DependencyInjection ;
5
+
6
+ namespace EventStore . Plugins . Subsystems ;
7
+
8
+ public interface ISubsystem {
9
+ IApplicationBuilder Configure ( IApplicationBuilder builder ) ;
10
+ IServiceCollection ConfigureServices ( IServiceCollection services ) ;
11
+ IEnumerable < Task > Start ( ) ;
12
+ void Stop ( ) ;
13
+ }
Original file line number Diff line number Diff line change
1
+ namespace EventStore . Plugins . Subsystems ;
2
+
3
+ public interface ISubsystemFactory < TArg > {
4
+ ISubsystem Create ( TArg arg ) ;
5
+ }
Original file line number Diff line number Diff line change
1
+ using System . Collections . Generic ;
2
+
3
+ namespace EventStore . Plugins . Subsystems ;
4
+
5
+ // A plugin that can create multiple subsystems.
6
+ // A TArg is required to produce each subsystem from its respective factory.
7
+ public interface ISubsystemsPlugin < TArg > {
8
+ string Name { get ; }
9
+ string Version { get ; }
10
+ string CommandLineName { get ; }
11
+ IEnumerable < ISubsystemFactory < TArg > > GetSubsystemFactories ( string configPath ) ;
12
+ }
You can’t perform that action at this time.
0 commit comments