From 4a767b20b4e653ea91754c03950c891b08bfed19 Mon Sep 17 00:00:00 2001 From: jebbs Date: Thu, 20 Oct 2022 14:36:09 +0800 Subject: [PATCH] move package outbound/balancer --- outbound/balancer.go | 2 +- {balancer => outbound/balancer}/balancer.go | 0 {balancer => outbound/balancer}/balancer_select.go | 0 {balancer => outbound/balancer}/balancer_select_test.go | 0 {balancer => outbound/balancer}/healthcheck.go | 0 {balancer => outbound/balancer}/healthcheck_nodes.go | 0 {balancer => outbound/balancer}/leastload.go | 0 {balancer => outbound/balancer}/leastping.go | 0 {balancer => outbound/balancer}/ping.go | 0 {balancer => outbound/balancer}/rtt_storage.go | 0 {balancer => outbound/balancer}/rtt_storage_test.go | 0 {balancer => outbound/balancer}/weight.go | 0 {balancer => outbound/balancer}/weight_test.go | 2 +- outbound/leastload.go | 2 +- outbound/leastping.go | 2 +- 15 files changed, 4 insertions(+), 4 deletions(-) rename {balancer => outbound/balancer}/balancer.go (100%) rename {balancer => outbound/balancer}/balancer_select.go (100%) rename {balancer => outbound/balancer}/balancer_select_test.go (100%) rename {balancer => outbound/balancer}/healthcheck.go (100%) rename {balancer => outbound/balancer}/healthcheck_nodes.go (100%) rename {balancer => outbound/balancer}/leastload.go (100%) rename {balancer => outbound/balancer}/leastping.go (100%) rename {balancer => outbound/balancer}/ping.go (100%) rename {balancer => outbound/balancer}/rtt_storage.go (100%) rename {balancer => outbound/balancer}/rtt_storage_test.go (100%) rename {balancer => outbound/balancer}/weight.go (100%) rename {balancer => outbound/balancer}/weight_test.go (96%) diff --git a/outbound/balancer.go b/outbound/balancer.go index 344a3956..bc3d3149 100644 --- a/outbound/balancer.go +++ b/outbound/balancer.go @@ -7,8 +7,8 @@ import ( "net" "github.com/sagernet/sing-box/adapter" - "github.com/sagernet/sing-box/balancer" "github.com/sagernet/sing-box/log" + "github.com/sagernet/sing-box/outbound/balancer" "github.com/sagernet/sing/common" E "github.com/sagernet/sing/common/exceptions" M "github.com/sagernet/sing/common/metadata" diff --git a/balancer/balancer.go b/outbound/balancer/balancer.go similarity index 100% rename from balancer/balancer.go rename to outbound/balancer/balancer.go diff --git a/balancer/balancer_select.go b/outbound/balancer/balancer_select.go similarity index 100% rename from balancer/balancer_select.go rename to outbound/balancer/balancer_select.go diff --git a/balancer/balancer_select_test.go b/outbound/balancer/balancer_select_test.go similarity index 100% rename from balancer/balancer_select_test.go rename to outbound/balancer/balancer_select_test.go diff --git a/balancer/healthcheck.go b/outbound/balancer/healthcheck.go similarity index 100% rename from balancer/healthcheck.go rename to outbound/balancer/healthcheck.go diff --git a/balancer/healthcheck_nodes.go b/outbound/balancer/healthcheck_nodes.go similarity index 100% rename from balancer/healthcheck_nodes.go rename to outbound/balancer/healthcheck_nodes.go diff --git a/balancer/leastload.go b/outbound/balancer/leastload.go similarity index 100% rename from balancer/leastload.go rename to outbound/balancer/leastload.go diff --git a/balancer/leastping.go b/outbound/balancer/leastping.go similarity index 100% rename from balancer/leastping.go rename to outbound/balancer/leastping.go diff --git a/balancer/ping.go b/outbound/balancer/ping.go similarity index 100% rename from balancer/ping.go rename to outbound/balancer/ping.go diff --git a/balancer/rtt_storage.go b/outbound/balancer/rtt_storage.go similarity index 100% rename from balancer/rtt_storage.go rename to outbound/balancer/rtt_storage.go diff --git a/balancer/rtt_storage_test.go b/outbound/balancer/rtt_storage_test.go similarity index 100% rename from balancer/rtt_storage_test.go rename to outbound/balancer/rtt_storage_test.go diff --git a/balancer/weight.go b/outbound/balancer/weight.go similarity index 100% rename from balancer/weight.go rename to outbound/balancer/weight.go diff --git a/balancer/weight_test.go b/outbound/balancer/weight_test.go similarity index 96% rename from balancer/weight_test.go rename to outbound/balancer/weight_test.go index 82555e9f..a231c344 100644 --- a/balancer/weight_test.go +++ b/outbound/balancer/weight_test.go @@ -4,9 +4,9 @@ import ( "reflect" "testing" - "github.com/sagernet/sing-box/balancer" "github.com/sagernet/sing-box/log" "github.com/sagernet/sing-box/option" + "github.com/sagernet/sing-box/outbound/balancer" ) func TestWeight(t *testing.T) { diff --git a/outbound/leastload.go b/outbound/leastload.go index 3defa8ec..80cd7e96 100644 --- a/outbound/leastload.go +++ b/outbound/leastload.go @@ -2,10 +2,10 @@ package outbound import ( "github.com/sagernet/sing-box/adapter" - "github.com/sagernet/sing-box/balancer" C "github.com/sagernet/sing-box/constant" "github.com/sagernet/sing-box/log" "github.com/sagernet/sing-box/option" + "github.com/sagernet/sing-box/outbound/balancer" ) var ( diff --git a/outbound/leastping.go b/outbound/leastping.go index ea90355a..4cf2b40d 100644 --- a/outbound/leastping.go +++ b/outbound/leastping.go @@ -2,10 +2,10 @@ package outbound import ( "github.com/sagernet/sing-box/adapter" - "github.com/sagernet/sing-box/balancer" C "github.com/sagernet/sing-box/constant" "github.com/sagernet/sing-box/log" "github.com/sagernet/sing-box/option" + "github.com/sagernet/sing-box/outbound/balancer" ) var (