Documentation ¶
Index ¶
- Variables
- func RegisterRpcCargoToMgrServer(s *grpc.Server, srv RpcCargoToMgrServer)
- type Ack
- type AppInfo
- type CargoInfo
- func (*CargoInfo) Descriptor() ([]byte, []int)deprecated
- func (x *CargoInfo) GetIP() string
- func (x *CargoInfo) GetLat() float64
- func (x *CargoInfo) GetLon() float64
- func (x *CargoInfo) GetPort() string
- func (x *CargoInfo) GetTSize() float64
- func (*CargoInfo) ProtoMessage()
- func (x *CargoInfo) ProtoReflect() protoreflect.Message
- func (x *CargoInfo) Reset()
- func (x *CargoInfo) String() string
- type LockAck
- type ReleaseAck
- type ReplicaInfo
- func (*ReplicaInfo) Descriptor() ([]byte, []int)deprecated
- func (x *ReplicaInfo) GetCType() string
- func (x *ReplicaInfo) GetCargoID() []string
- func (x *ReplicaInfo) GetIP() []string
- func (x *ReplicaInfo) GetPort() []string
- func (*ReplicaInfo) ProtoMessage()
- func (x *ReplicaInfo) ProtoReflect() protoreflect.Message
- func (x *ReplicaInfo) Reset()
- func (x *ReplicaInfo) String() string
- type RpcCargoToMgrClient
- type RpcCargoToMgrServer
- type UnimplementedRpcCargoToMgrServer
- func (*UnimplementedRpcCargoToMgrServer) AcquireWriteLock(context.Context, *AppInfo) (*LockAck, error)
- func (*UnimplementedRpcCargoToMgrServer) GetReplicaInfo(context.Context, *AppInfo) (*ReplicaInfo, error)
- func (*UnimplementedRpcCargoToMgrServer) RegisterToMgr(context.Context, *CargoInfo) (*Ack, error)
- func (*UnimplementedRpcCargoToMgrServer) ReleaseWriteLock(context.Context, *AppInfo) (*ReleaseAck, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var File_cargoToMgr_proto protoreflect.FileDescriptor
Functions ¶
func RegisterRpcCargoToMgrServer ¶
func RegisterRpcCargoToMgrServer(s *grpc.Server, srv RpcCargoToMgrServer)
Types ¶
type Ack ¶
type Ack struct { ID string `protobuf:"bytes,1,opt,name=ID,proto3" json:"ID,omitempty"` Ack string `protobuf:"bytes,2,opt,name=ack,proto3" json:"ack,omitempty"` // contains filtered or unexported fields }
func (*Ack) Descriptor
deprecated
func (*Ack) ProtoMessage ¶
func (*Ack) ProtoMessage()
func (*Ack) ProtoReflect ¶
func (x *Ack) ProtoReflect() protoreflect.Message
type AppInfo ¶
type AppInfo struct { AppID string `protobuf:"bytes,1,opt,name=AppID,proto3" json:"AppID,omitempty"` // contains filtered or unexported fields }
func (*AppInfo) Descriptor
deprecated
func (*AppInfo) ProtoMessage ¶
func (*AppInfo) ProtoMessage()
func (*AppInfo) ProtoReflect ¶
func (x *AppInfo) ProtoReflect() protoreflect.Message
type CargoInfo ¶
type CargoInfo struct { IP string `protobuf:"bytes,1,opt,name=IP,proto3" json:"IP,omitempty"` Port string `protobuf:"bytes,2,opt,name=Port,proto3" json:"Port,omitempty"` TSize float64 `protobuf:"fixed64,3,opt,name=TSize,proto3" json:"TSize,omitempty"` Lat float64 `protobuf:"fixed64,4,opt,name=Lat,proto3" json:"Lat,omitempty"` Lon float64 `protobuf:"fixed64,5,opt,name=Lon,proto3" json:"Lon,omitempty"` // contains filtered or unexported fields }
func (*CargoInfo) Descriptor
deprecated
func (*CargoInfo) ProtoMessage ¶
func (*CargoInfo) ProtoMessage()
func (*CargoInfo) ProtoReflect ¶
func (x *CargoInfo) ProtoReflect() protoreflect.Message
type LockAck ¶
type LockAck struct { Locked bool `protobuf:"varint,1,opt,name=locked,proto3" json:"locked,omitempty"` // contains filtered or unexported fields }
func (*LockAck) Descriptor
deprecated
func (*LockAck) ProtoMessage ¶
func (*LockAck) ProtoMessage()
func (*LockAck) ProtoReflect ¶
func (x *LockAck) ProtoReflect() protoreflect.Message
type ReleaseAck ¶
type ReleaseAck struct { Released bool `protobuf:"varint,1,opt,name=released,proto3" json:"released,omitempty"` // contains filtered or unexported fields }
func (*ReleaseAck) Descriptor
deprecated
func (*ReleaseAck) Descriptor() ([]byte, []int)
Deprecated: Use ReleaseAck.ProtoReflect.Descriptor instead.
func (*ReleaseAck) GetReleased ¶
func (x *ReleaseAck) GetReleased() bool
func (*ReleaseAck) ProtoMessage ¶
func (*ReleaseAck) ProtoMessage()
func (*ReleaseAck) ProtoReflect ¶
func (x *ReleaseAck) ProtoReflect() protoreflect.Message
func (*ReleaseAck) Reset ¶
func (x *ReleaseAck) Reset()
func (*ReleaseAck) String ¶
func (x *ReleaseAck) String() string
type ReplicaInfo ¶
type ReplicaInfo struct { CargoID []string `protobuf:"bytes,1,rep,name=cargoID,proto3" json:"cargoID,omitempty"` IP []string `protobuf:"bytes,2,rep,name=IP,proto3" json:"IP,omitempty"` Port []string `protobuf:"bytes,3,rep,name=Port,proto3" json:"Port,omitempty"` CType string `protobuf:"bytes,4,opt,name=cType,proto3" json:"cType,omitempty"` // contains filtered or unexported fields }
func (*ReplicaInfo) Descriptor
deprecated
func (*ReplicaInfo) Descriptor() ([]byte, []int)
Deprecated: Use ReplicaInfo.ProtoReflect.Descriptor instead.
func (*ReplicaInfo) GetCType ¶
func (x *ReplicaInfo) GetCType() string
func (*ReplicaInfo) GetCargoID ¶
func (x *ReplicaInfo) GetCargoID() []string
func (*ReplicaInfo) GetIP ¶
func (x *ReplicaInfo) GetIP() []string
func (*ReplicaInfo) GetPort ¶
func (x *ReplicaInfo) GetPort() []string
func (*ReplicaInfo) ProtoMessage ¶
func (*ReplicaInfo) ProtoMessage()
func (*ReplicaInfo) ProtoReflect ¶
func (x *ReplicaInfo) ProtoReflect() protoreflect.Message
func (*ReplicaInfo) Reset ¶
func (x *ReplicaInfo) Reset()
func (*ReplicaInfo) String ¶
func (x *ReplicaInfo) String() string
type RpcCargoToMgrClient ¶
type RpcCargoToMgrClient interface { RegisterToMgr(ctx context.Context, in *CargoInfo, opts ...grpc.CallOption) (*Ack, error) GetReplicaInfo(ctx context.Context, in *AppInfo, opts ...grpc.CallOption) (*ReplicaInfo, error) AcquireWriteLock(ctx context.Context, in *AppInfo, opts ...grpc.CallOption) (*LockAck, error) ReleaseWriteLock(ctx context.Context, in *AppInfo, opts ...grpc.CallOption) (*ReleaseAck, error) }
RpcCargoToMgrClient is the client API for RpcCargoToMgr service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewRpcCargoToMgrClient ¶
func NewRpcCargoToMgrClient(cc grpc.ClientConnInterface) RpcCargoToMgrClient
type RpcCargoToMgrServer ¶
type RpcCargoToMgrServer interface { RegisterToMgr(context.Context, *CargoInfo) (*Ack, error) GetReplicaInfo(context.Context, *AppInfo) (*ReplicaInfo, error) AcquireWriteLock(context.Context, *AppInfo) (*LockAck, error) ReleaseWriteLock(context.Context, *AppInfo) (*ReleaseAck, error) }
RpcCargoToMgrServer is the server API for RpcCargoToMgr service.
type UnimplementedRpcCargoToMgrServer ¶
type UnimplementedRpcCargoToMgrServer struct { }
UnimplementedRpcCargoToMgrServer can be embedded to have forward compatible implementations.
func (*UnimplementedRpcCargoToMgrServer) AcquireWriteLock ¶
func (*UnimplementedRpcCargoToMgrServer) GetReplicaInfo ¶
func (*UnimplementedRpcCargoToMgrServer) GetReplicaInfo(context.Context, *AppInfo) (*ReplicaInfo, error)
func (*UnimplementedRpcCargoToMgrServer) RegisterToMgr ¶
func (*UnimplementedRpcCargoToMgrServer) ReleaseWriteLock ¶
func (*UnimplementedRpcCargoToMgrServer) ReleaseWriteLock(context.Context, *AppInfo) (*ReleaseAck, error)
Click to show internal directories.
Click to hide internal directories.