utils

package
v0.0.0-...-6e78c53 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package utils xxx

Index

Constants

View Source
const (
	// IpvsPersistFileName xxx
	IpvsPersistFileName = "ipvsConfig.yaml"
	// RcLocalIpvsFlag xxx
	RcLocalIpvsFlag = "IPVS_START_UP"
)

Variables

This section is empty.

Functions

func BuildRealServer

func BuildRealServer(real string) *ipvs.RealServer

BuildRealServer build real to ipvs.RealServer

func BuildVirtualServer

func BuildVirtualServer(vip string, scheduler string) *ipvs.VirtualServer

BuildVirtualServer build vip to ipvs.VirtualServer

func SetIpvsStartup

func SetIpvsStartup(ipvsPersistDir string, toolPath string) error

SetIpvsStartup xxx

func SplitServer

func SplitServer(server string) (string, uint32)

SplitServer split server to ip, port

func WriteToFile

func WriteToFile(filePath string, content string) error

WriteToFile xxx

Types

type EndPoint

type EndPoint struct {
	IP   string
	Port uint32
}

EndPoint wrap IP&Port

func (EndPoint) String

func (ep EndPoint) String() string

String trans endpoint to ip:port

Directories

Path Synopsis
Package metrics xxx
Package metrics xxx

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL