Documentation ¶
Index ¶
- func SlaveCount() int
- type AgentStatusResp
- type ClusterInfo
- type MasterServer
- func (m *MasterServer) DoExecuteTask(address string, request *pb.ExecuteTaskRequest) (*pb.ExecuteTaskResponse, error)
- func (m *MasterServer) ExecuteTask(ctx context.Context, in *pb.ExecuteTaskRequest) (*pb.ExecuteTaskResponse, error)
- func (m *MasterServer) HeartBeat(stream pb.SqueezeService_HeartBeatServer) error
- func (m *MasterServer) Initialize(args *ServerArgs) error
- func (m *MasterServer) Start(stopChan <-chan struct{}) error
- type NodeType
- type Proxy
- type Server
- type ServerArgs
- type ServerBase
- type SlaveConn
- type SlaveServer
- func (s *SlaveServer) ExecuteTask(ctx context.Context, req *pb.ExecuteTaskRequest) (*pb.ExecuteTaskResponse, error)
- func (s *SlaveServer) HeartBeat(stream pb.SqueezeService_HeartBeatServer) error
- func (s *SlaveServer) Initialize(args *ServerArgs) error
- func (s *SlaveServer) Start(stopChan <-chan struct{}) error
- type SlaveStream
- type WebServer
- type Work
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SlaveCount ¶
func SlaveCount() int
Types ¶
type AgentStatusResp ¶
type ClusterInfo ¶ added in v0.1.1
type ClusterInfo struct { Data []AgentStatusResp `json:"data"` Error string `json:"error"` }
type MasterServer ¶
type MasterServer struct { ServerBase // contains filtered or unexported fields }
func (*MasterServer) DoExecuteTask ¶
func (m *MasterServer) DoExecuteTask(address string, request *pb.ExecuteTaskRequest) (*pb.ExecuteTaskResponse, error)
func (*MasterServer) ExecuteTask ¶
func (m *MasterServer) ExecuteTask(ctx context.Context, in *pb.ExecuteTaskRequest) (*pb.ExecuteTaskResponse, error)
func (*MasterServer) HeartBeat ¶
func (m *MasterServer) HeartBeat(stream pb.SqueezeService_HeartBeatServer) error
func (*MasterServer) Initialize ¶
func (m *MasterServer) Initialize(args *ServerArgs) error
func (*MasterServer) Start ¶
func (m *MasterServer) Start(stopChan <-chan struct{}) error
type Server ¶
type Server interface { Initialize(args *ServerArgs) error Start(stopChan <-chan struct{}) error }
type ServerArgs ¶
type ServerArgs struct { HTTPAddr string // The listening address for http GRPCAddr string // The listening address for grpc HttpMasterAddr string // Master's HTTP Address GrpcMasterAddr string // Master's GRPC Address ReportInterval time.Duration // Heartbeat reporting interval ResultCapacity int Args interface{} }
var SrvArgs ServerArgs
func NewServerArgs ¶
func NewServerArgs() *ServerArgs
type ServerBase ¶
type ServerBase struct { Mode NodeType // contains filtered or unexported fields }
func (*ServerBase) Initialize ¶
func (s *ServerBase) Initialize(args *ServerArgs) error
type SlaveConn ¶
type SlaveConn struct { PeerAddr string ConnID string GrpcPort int Status string // contains filtered or unexported fields }
func GetSlaveConns ¶ added in v0.1.1
func GetSlaveConns() []*SlaveConn
type SlaveServer ¶
type SlaveServer struct { ServerBase // contains filtered or unexported fields }
func (*SlaveServer) ExecuteTask ¶
func (s *SlaveServer) ExecuteTask(ctx context.Context, req *pb.ExecuteTaskRequest) (*pb.ExecuteTaskResponse, error)
func (*SlaveServer) HeartBeat ¶
func (s *SlaveServer) HeartBeat(stream pb.SqueezeService_HeartBeatServer) error
func (*SlaveServer) Initialize ¶
func (s *SlaveServer) Initialize(args *ServerArgs) error
func (*SlaveServer) Start ¶
func (s *SlaveServer) Start(stopChan <-chan struct{}) error
type SlaveStream ¶
type SlaveStream interface { Send(*pb.HeartBeatResponse) error Recv() (*pb.HeartBeatRequest, error) grpc.ServerStream }
type WebServer ¶
type WebServer struct {
ServerBase
}
func (*WebServer) Initialize ¶
func (s *WebServer) Initialize(args *ServerArgs) error
type Work ¶
type Work struct { // Protocol constructor Builder build.ProtoBuilder // Request task to be executed Req *pb.ExecuteTaskRequest // Requests is the total number of requests to make. Requests int // Number of goroutines to run (Concurrent connections) Workers int Ctx context.Context Cancel context.CancelFunc // RateLimit is the rate limit in queries per second. RateLimit float64 // The capacity of the result of the collector channel ResultCapacity int // contains filtered or unexported fields }
func (*Work) Finish ¶
Finish waits for worker goroutines & collecotr goroutine to exit and return time spent on pressure measurement.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.