/
aprogrammer
/
reverse-proxy-ms-yarp
Обзор
Документация
Войти
/
aprogrammer
/
reverse-proxy-ms-yarp
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/ReverseProxy/LoadBalancing/ILoadBalancingPolicy.cs
25 строк
761 B
Kahbazi
File Scoped Namespaces (#1352)
12 ноя 2021, 21:53
Не верифицирован
12 ноя 2021, 21:53
44f13d9
Код
Авторство
О чём код?
// Copyright (c) Microsoft Corporation. // Licensed under the MIT License. using System.Collections.Generic; using Microsoft.AspNetCore.Http; using Yarp.ReverseProxy.Model; namespace Yarp.ReverseProxy.LoadBalancing; /// <summary> /// Provides a method that applies a load balancing policy /// to select a destination. /// </summary> public interface ILoadBalancingPolicy { /// <summary> /// A unique identifier for this load balancing policy. This will be referenced from config. /// </summary> string Name { get; } /// <summary> /// Picks a destination to send traffic to. /// </summary> DestinationState? PickDestination(HttpContext context, ClusterState cluster, IReadOnlyList<DestinationState> availableDestinations); }