예제 #1
0
        public async Task Invoke(HttpContext context, HealthEndpoint endpoint)
        {
            _endpoint = endpoint;

            if (RequestVerbAndPathMatch(context.Request.Method, context.Request.Path.Value))
            {
                await HandleHealthRequestAsync(context);
            }
            else
            {
                await _next(context);
            }
        }
예제 #2
0
        public async Task Invoke(HttpContext context, HealthEndpoint endpoint)
        {
            this.endpoint = endpoint;

            if (IsHealthRequest(context))
            {
                await HandleHealthRequestAsync(context);
            }
            else
            {
                await _next(context);
            }
        }
예제 #3
0
 public HealthEndpointMiddleware(RequestDelegate next, HealthEndpoint endpoint, IEnumerable <IManagementOptions> mgmtOptions, ILogger <InfoEndpointMiddleware> logger = null)
     : base(endpoint, mgmtOptions, logger: logger)
 {
     _next = next;
 }
 public HealthEndpointMiddleware(RequestDelegate next, HealthEndpoint endpoint, ILogger <HealthEndpointMiddleware> logger = null)
     : base(endpoint, logger)
 {
     _next = next;
 }