health

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2018 License: MIT Imports: 8 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterHealthServer

func RegisterHealthServer(s *grpc.Server, srv HealthServer)

Types

type HealthClient

type HealthClient interface {
	Info(ctx context.Context, in *InfoRequest, opts ...grpc.CallOption) (*InfoResponse, error)
	Health(ctx context.Context, in *types.Empty, opts ...grpc.CallOption) (*HealthResponse, error)
}

HealthClient is the client API for Health service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewHealthClient

func NewHealthClient(cc *grpc.ClientConn) HealthClient

type HealthResponse

type HealthResponse struct {
	Health               *NodeHealth `protobuf:"bytes,1,opt,name=health" json:"health,omitempty"`
	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
	XXX_unrecognized     []byte      `json:"-"`
	XXX_sizecache        int32       `json:"-"`
}

func (*HealthResponse) Descriptor

func (*HealthResponse) Descriptor() ([]byte, []int)

func (*HealthResponse) GetHealth

func (m *HealthResponse) GetHealth() *NodeHealth

func (*HealthResponse) ProtoMessage

func (*HealthResponse) ProtoMessage()

func (*HealthResponse) Reset

func (m *HealthResponse) Reset()

func (*HealthResponse) String

func (m *HealthResponse) String() string

func (*HealthResponse) XXX_DiscardUnknown

func (m *HealthResponse) XXX_DiscardUnknown()

func (*HealthResponse) XXX_Marshal

func (m *HealthResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HealthResponse) XXX_Merge

func (dst *HealthResponse) XXX_Merge(src proto.Message)

func (*HealthResponse) XXX_Size

func (m *HealthResponse) XXX_Size() int

func (*HealthResponse) XXX_Unmarshal

func (m *HealthResponse) XXX_Unmarshal(b []byte) error

type HealthServer

type HealthServer interface {
	Info(context.Context, *InfoRequest) (*InfoResponse, error)
	Health(context.Context, *types.Empty) (*HealthResponse, error)
}

HealthServer is the server API for Health service.

type InfoRequest added in v0.2.0

type InfoRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InfoRequest) Descriptor added in v0.2.0

func (*InfoRequest) Descriptor() ([]byte, []int)

func (*InfoRequest) ProtoMessage added in v0.2.0

func (*InfoRequest) ProtoMessage()

func (*InfoRequest) Reset added in v0.2.0

func (m *InfoRequest) Reset()

func (*InfoRequest) String added in v0.2.0

func (m *InfoRequest) String() string

func (*InfoRequest) XXX_DiscardUnknown added in v0.2.0

func (m *InfoRequest) XXX_DiscardUnknown()

func (*InfoRequest) XXX_Marshal added in v0.2.0

func (m *InfoRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InfoRequest) XXX_Merge added in v0.2.0

func (dst *InfoRequest) XXX_Merge(src proto.Message)

func (*InfoRequest) XXX_Size added in v0.2.0

func (m *InfoRequest) XXX_Size() int

func (*InfoRequest) XXX_Unmarshal added in v0.2.0

func (m *InfoRequest) XXX_Unmarshal(b []byte) error

type InfoResponse added in v0.2.0

type InfoResponse struct {
	ID                   string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InfoResponse) Descriptor added in v0.2.0

func (*InfoResponse) Descriptor() ([]byte, []int)

func (*InfoResponse) GetID added in v0.2.0

func (m *InfoResponse) GetID() string

func (*InfoResponse) ProtoMessage added in v0.2.0

func (*InfoResponse) ProtoMessage()

func (*InfoResponse) Reset added in v0.2.0

func (m *InfoResponse) Reset()

func (*InfoResponse) String added in v0.2.0

func (m *InfoResponse) String() string

func (*InfoResponse) XXX_DiscardUnknown added in v0.2.0

func (m *InfoResponse) XXX_DiscardUnknown()

func (*InfoResponse) XXX_Marshal added in v0.2.0

func (m *InfoResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InfoResponse) XXX_Merge added in v0.2.0

func (dst *InfoResponse) XXX_Merge(src proto.Message)

func (*InfoResponse) XXX_Size added in v0.2.0

func (m *InfoResponse) XXX_Size() int

func (*InfoResponse) XXX_Unmarshal added in v0.2.0

func (m *InfoResponse) XXX_Unmarshal(b []byte) error

type NodeHealth

type NodeHealth struct {
	OSName    string `protobuf:"bytes,1,opt,name=os_name,json=osName,proto3" json:"os_name,omitempty"`
	OSVersion string `protobuf:"bytes,2,opt,name=os_version,json=osVersion,proto3" json:"os_version,omitempty"`
	// TODO: use gogoproto.stdtime (returning panic: message/group field time.Time:bytes without pointer when trying to use)
	StartedAt            *types.Timestamp `protobuf:"bytes,3,opt,name=started_at,json=startedAt" json:"started_at,omitempty"`
	Cpus                 int64            `protobuf:"varint,4,opt,name=cpus,proto3" json:"cpus,omitempty"`
	MemoryTotal          int64            `protobuf:"varint,5,opt,name=memory_total,json=memoryTotal,proto3" json:"memory_total,omitempty"`
	MemoryFree           int64            `protobuf:"varint,6,opt,name=memory_free,json=memoryFree,proto3" json:"memory_free,omitempty"`
	MemoryUsed           int64            `protobuf:"varint,7,opt,name=memory_used,json=memoryUsed,proto3" json:"memory_used,omitempty"`
	Peers                []*Peer          `protobuf:"bytes,8,rep,name=peers" json:"peers,omitempty"`
	XXX_NoUnkeyedLiteral struct{}         `json:"-"`
	XXX_unrecognized     []byte           `json:"-"`
	XXX_sizecache        int32            `json:"-"`
}

func (*NodeHealth) Descriptor

func (*NodeHealth) Descriptor() ([]byte, []int)

func (*NodeHealth) GetCpus

func (m *NodeHealth) GetCpus() int64

func (*NodeHealth) GetMemoryFree

func (m *NodeHealth) GetMemoryFree() int64

func (*NodeHealth) GetMemoryTotal

func (m *NodeHealth) GetMemoryTotal() int64

func (*NodeHealth) GetMemoryUsed

func (m *NodeHealth) GetMemoryUsed() int64

func (*NodeHealth) GetOSName

func (m *NodeHealth) GetOSName() string

func (*NodeHealth) GetOSVersion

func (m *NodeHealth) GetOSVersion() string

func (*NodeHealth) GetPeers

func (m *NodeHealth) GetPeers() []*Peer

func (*NodeHealth) GetStartedAt

func (m *NodeHealth) GetStartedAt() *types.Timestamp

func (*NodeHealth) ProtoMessage

func (*NodeHealth) ProtoMessage()

func (*NodeHealth) Reset

func (m *NodeHealth) Reset()

func (*NodeHealth) Started

func (m *NodeHealth) Started() (time.Time, error)

Started returns the timestamp as time.Time

func (*NodeHealth) String

func (m *NodeHealth) String() string

func (*NodeHealth) XXX_DiscardUnknown

func (m *NodeHealth) XXX_DiscardUnknown()

func (*NodeHealth) XXX_Marshal

func (m *NodeHealth) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*NodeHealth) XXX_Merge

func (dst *NodeHealth) XXX_Merge(src proto.Message)

func (*NodeHealth) XXX_Size

func (m *NodeHealth) XXX_Size() int

func (*NodeHealth) XXX_Unmarshal

func (m *NodeHealth) XXX_Unmarshal(b []byte) error

type Peer

type Peer struct {
	ID                   string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Address              string   `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Peer) Descriptor

func (*Peer) Descriptor() ([]byte, []int)

func (*Peer) GetAddress added in v0.2.0

func (m *Peer) GetAddress() string

func (*Peer) GetID added in v0.2.0

func (m *Peer) GetID() string

func (*Peer) ProtoMessage

func (*Peer) ProtoMessage()

func (*Peer) Reset

func (m *Peer) Reset()

func (*Peer) String

func (m *Peer) String() string

func (*Peer) XXX_DiscardUnknown

func (m *Peer) XXX_DiscardUnknown()

func (*Peer) XXX_Marshal

func (m *Peer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Peer) XXX_Merge

func (dst *Peer) XXX_Merge(src proto.Message)

func (*Peer) XXX_Size

func (m *Peer) XXX_Size() int

func (*Peer) XXX_Unmarshal

func (m *Peer) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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