Skip to main content

Policy Groups

A policy group contains nodes or other policy groups and selects one either manually or automatically. Policy groups are declared in [Proxy Group] and may be nested.

select

Select a policy manually.

url-test

Tests all nodes periodically and selects the one with the lowest latency.

ParameterDescription
urlTest URL; Loon sends a header request
intervalTest interval in seconds
toleranceDo not switch if the latency difference between the current and new best node is below this value, in milliseconds

fallback

Tests nodes periodically and selects the first available node in the list.

ParameterDescription
urlTest URL
intervalTest interval in seconds
max-timeoutA node is unavailable if it exceeds this time, in milliseconds

load-balance

Distributes requests among child policies using the selected algorithm.

ParameterDescription
urlTest URL
intervalTest interval in seconds
max-timeoutA node is unavailable if it exceeds this time, in milliseconds
algorithmLoad-balancing algorithm

Supported algorithms:

  • Random: Select randomly.
  • PCC: Keep the same hostname on the same node.
  • Round-Robin: Select nodes in sequence.