topology

package
v0.0.0-...-46d4b59 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTopologyCommand

func NewTopologyCommand() *cobra.Command

Types

type CreatePoolRpc

type CreatePoolRpc struct {
	Info    *basecmd.Rpc
	Request *topology.CreatePoolRequest
	// contains filtered or unexported fields
}

func (*CreatePoolRpc) NewRpcClient

func (cpRpc *CreatePoolRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*CreatePoolRpc) Stub_Func

func (cpRpc *CreatePoolRpc) Stub_Func(ctx context.Context) (interface{}, error)

type CreateServerRpc

type CreateServerRpc struct {
	Info    *basecmd.Rpc
	Request *topology.ServerRegistRequest
	// contains filtered or unexported fields
}

func (*CreateServerRpc) NewRpcClient

func (csRpc *CreateServerRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*CreateServerRpc) Stub_Func

func (csRpc *CreateServerRpc) Stub_Func(ctx context.Context) (interface{}, error)

type CreateZoneRpc

type CreateZoneRpc struct {
	Info    *basecmd.Rpc
	Request *topology.CreateZoneRequest
	// contains filtered or unexported fields
}

func (*CreateZoneRpc) NewRpcClient

func (czRpc *CreateZoneRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*CreateZoneRpc) Stub_Func

func (czRpc *CreateZoneRpc) Stub_Func(ctx context.Context) (interface{}, error)

type DeletePoolRpc

type DeletePoolRpc struct {
	Info    *basecmd.Rpc
	Request *topology.DeletePoolRequest
	// contains filtered or unexported fields
}

func (*DeletePoolRpc) NewRpcClient

func (dpRpc *DeletePoolRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*DeletePoolRpc) Stub_Func

func (dpRpc *DeletePoolRpc) Stub_Func(ctx context.Context) (interface{}, error)

type DeleteServerRpc

type DeleteServerRpc struct {
	Info    *basecmd.Rpc
	Request *topology.DeleteServerRequest
	// contains filtered or unexported fields
}

func (*DeleteServerRpc) NewRpcClient

func (dsRpc *DeleteServerRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*DeleteServerRpc) Stub_Func

func (dsRpc *DeleteServerRpc) Stub_Func(ctx context.Context) (interface{}, error)

type DeleteZoneRpc

type DeleteZoneRpc struct {
	Info    *basecmd.Rpc
	Request *topology.DeleteZoneRequest
	// contains filtered or unexported fields
}

func (*DeleteZoneRpc) NewRpcClient

func (dzRpc *DeleteZoneRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*DeleteZoneRpc) Stub_Func

func (dzRpc *DeleteZoneRpc) Stub_Func(ctx context.Context) (interface{}, error)

type ListPoolRpc

type ListPoolRpc struct {
	Info    *basecmd.Rpc
	Request *topology.ListPoolRequest
	// contains filtered or unexported fields
}

func (*ListPoolRpc) NewRpcClient

func (lpRpc *ListPoolRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*ListPoolRpc) Stub_Func

func (lpRpc *ListPoolRpc) Stub_Func(ctx context.Context) (interface{}, error)

type ListPoolZoneRpc

type ListPoolZoneRpc struct {
	Info    *basecmd.Rpc
	Request *topology.ListPoolZoneRequest
	// contains filtered or unexported fields
}

func (*ListPoolZoneRpc) NewRpcClient

func (lpzRpc *ListPoolZoneRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*ListPoolZoneRpc) Stub_Func

func (lpzRpc *ListPoolZoneRpc) Stub_Func(ctx context.Context) (interface{}, error)

type ListZoneServerRpc

type ListZoneServerRpc struct {
	Info    *basecmd.Rpc
	Request *topology.ListZoneServerRequest
	// contains filtered or unexported fields
}

func (*ListZoneServerRpc) NewRpcClient

func (lzsRpc *ListZoneServerRpc) NewRpcClient(cc grpc.ClientConnInterface)

func (*ListZoneServerRpc) Stub_Func

func (lzsRpc *ListZoneServerRpc) Stub_Func(ctx context.Context) (interface{}, error)

type Policy

type Policy struct {
	ReplicaNum uint32 `json:"replicaNum"`
	CopysetNum uint64 `json:"copysetNum"`
	ZoneNum    uint32 `json:"zoneNum"`
}

type Pool

type Pool struct {
	Name         string `json:"name"`
	ReplicasNum  uint32 `json:"replicasnum"`
	ZoneNum      uint32 `json:"zonenum"`
	CopysetNum   uint64 `json:"copysetnum"`
	PoolType     uint64 `json:"type"`
	ScatterWidth uint64 `json:"scatterwidth"`
	PhysicalPool string `json:"physicalpool"`
}

type Server

type Server struct {
	Name         string `json:"name"`
	InternalIp   string `json:"internalip"`
	InternalPort uint32 `json:"internalport"`
	ExternalIp   string `json:"externalip"`
	ExternalPort uint32 `json:"externalport"`
	ZoneName     string `json:"zone"`
	PoolName     string `json:"pool"`
}

type Topology

type Topology struct {
	Servers []Server `json:"servers"`
	Zones   []Zone   `json:"-"`
	Pools   []Pool   `json:"pools"`
	PoolNum uint64   `json:"npools"`
}

type TopologyCommand

type TopologyCommand struct {
	basecmd.FinalCurveCmd
	// contains filtered or unexported fields
}

func (*TopologyCommand) AddFlags

func (tCmd *TopologyCommand) AddFlags()

func (*TopologyCommand) Init

func (tCmd *TopologyCommand) Init(cmd *cobra.Command, args []string) error

func (*TopologyCommand) Print

func (tCmd *TopologyCommand) Print(cmd *cobra.Command, args []string) error

func (*TopologyCommand) ResultPlainOutput

func (tCmd *TopologyCommand) ResultPlainOutput() error

func (*TopologyCommand) RunCommand

func (tCmd *TopologyCommand) RunCommand(cmd *cobra.Command, args []string) error

type Zone

type Zone struct {
	Name     string
	PoolName string
}

Jump to

Keyboard shortcuts

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