0
mirror of https://github.com/XTLS/Xray-core.git synced 2025-06-12 03:19:36 +03:00

Add observatory / latestPing balancing strategy

Co-authored-by: Shelikhoo <xiaokangwang@outlook.com>
This commit is contained in:
世界
2021-04-09 05:20:30 +08:00
parent 77d0419aca
commit 5c366db847
21 changed files with 1127 additions and 31 deletions

14
infra/conf/observatory.go Normal file
View File

@ -0,0 +1,14 @@
package conf
import (
"github.com/golang/protobuf/proto"
"github.com/xtls/xray-core/app/observatory"
)
type ObservatoryConfig struct {
SubjectSelector []string `json:"subjectSelector"`
}
func (o ObservatoryConfig) Build() (proto.Message, error) {
return &observatory.Config{SubjectSelector: o.SubjectSelector}, nil
}