@@ -39,47 +39,44 @@ public void Configure(IApplicationBuilder app)
3939 if ( _env . IsDevelopment ( ) )
4040 app . UseDeveloperExceptionPage ( ) ;
4141
42- app . UseSerilogRequestLogging ( ) ;
42+ app . UseSerilogRequestLogging ( )
43+ . UseApplicationGraphQL < StoreSchema > ( )
44+ . UseRouting ( )
45+ . UseEndpoints (
46+ endpoints =>
47+ {
48+ endpoints . MapControllers ( ) ;
4349
44- app . UseApplicationGraphQL < StoreSchema > ( ) ;
45-
46- app . UseRouting ( )
47- . UseEndpoints ( endpoints =>
48- {
49- endpoints . MapControllers ( ) ;
50+ endpoints . MapDumpConfig (
51+ pattern : "/dump-config" ,
52+ configInfo : ( _configuration as IConfigurationRoot ) . GetDebugView ( ) ,
53+ isDevelopment : _env . IsDevelopment ( ) ) ;
5054
51- endpoints . MapDumpConfig (
52- pattern : "/dump-config" ,
53- configInfo : ( _configuration as IConfigurationRoot ) . GetDebugView ( ) ,
54- isDevelopment : _env . IsDevelopment ( ) ) ;
55-
56- endpoints . MapApplicationHealthChecks (
57- pattern : _configuration [ "HealthChecksPatterns:Health" ] ,
58- predicate : registration
59- => registration . Tags . Any ( ) is false ) ;
60-
61- endpoints . MapApplicationHealthChecks (
62- pattern : _configuration [ "HealthChecksPatterns:Liveness" ] ,
63- predicate : registration
64- => registration . Tags . Any ( item
65- => _livenessTags . Contains ( item ) ) ) ;
66-
67- endpoints . MapApplicationHealthChecks (
68- pattern : _configuration [ "HealthChecksPatterns:Readiness" ] ,
69- predicate : registration
70- => registration . Tags . Any ( item
71- => _readinessTags . Contains ( item ) ) ) ;
55+ endpoints . MapApplicationHealthChecks (
56+ pattern : _configuration [ "HealthChecksPatterns:Health" ] ,
57+ predicate : registration
58+ => registration . Tags . Any ( ) is false ) ;
7259
73- endpoints . MapHealthChecks (
74- pattern : _configuration [ "HealthChecksPatterns:UI" ] ,
75- options : new ( ) { ResponseWriter = UIResponseWriter . WriteHealthCheckUIResponse } ) ;
76- } ) ;
60+ endpoints . MapApplicationHealthChecks (
61+ pattern : _configuration [ "HealthChecksPatterns:Liveness" ] ,
62+ predicate : registration
63+ => registration . Tags . Any ( item
64+ => _livenessTags . Contains ( item ) ) ) ;
65+
66+ endpoints . MapApplicationHealthChecks (
67+ pattern : _configuration [ "HealthChecksPatterns:Readiness" ] ,
68+ predicate : registration
69+ => registration . Tags . Any ( item
70+ => _readinessTags . Contains ( item ) ) ) ;
71+
72+ endpoints . MapHealthChecks (
73+ pattern : _configuration [ "HealthChecksPatterns:UI" ] ,
74+ options : new ( ) { ResponseWriter = UIResponseWriter . WriteHealthCheckUIResponse } ) ;
75+ } ) ;
7776 }
7877
7978 public void ConfigureServices ( IServiceCollection services )
8079 {
81- services . AddControllers ( ) ;
82-
8380 services
8481 . AddBuilders ( )
8582 . AddRepositories ( )
@@ -88,7 +85,8 @@ public void ConfigureServices(IServiceCollection services)
8885 . AddApplicationServices ( )
8986 . AddApplicationMessageServices ( )
9087 . AddApplicationSubjects ( )
91- . AddApplicationAutoMapper ( ) ;
88+ . AddApplicationAutoMapper ( )
89+ . AddControllers ( ) ;
9290
9391 services . AddApplicationDbContext ( options =>
9492 {
0 commit comments