Documentation ¶
Index ¶
- Variables
- func RegisterPlacementServer(s grpc.ServiceRegistrar, srv PlacementServer)
- type Host
- func (*Host) Descriptor() ([]byte, []int)deprecated
- func (x *Host) GetEntities() []string
- func (x *Host) GetId() string
- func (x *Host) GetLoad() int64
- func (x *Host) GetName() string
- func (x *Host) GetPort() int64
- func (*Host) ProtoMessage()
- func (x *Host) ProtoReflect() protoreflect.Message
- func (x *Host) Reset()
- func (x *Host) String() string
- type PlacementClient
- type PlacementOrder
- func (*PlacementOrder) Descriptor() ([]byte, []int)deprecated
- func (x *PlacementOrder) GetOperation() string
- func (x *PlacementOrder) GetTables() *PlacementTables
- func (*PlacementOrder) ProtoMessage()
- func (x *PlacementOrder) ProtoReflect() protoreflect.Message
- func (x *PlacementOrder) Reset()
- func (x *PlacementOrder) String() string
- type PlacementServer
- type PlacementTable
- func (*PlacementTable) Descriptor() ([]byte, []int)deprecated
- func (x *PlacementTable) GetHosts() map[uint64]string
- func (x *PlacementTable) GetLoadMap() map[string]*Host
- func (x *PlacementTable) GetSortedSet() []uint64
- func (x *PlacementTable) GetTotalLoad() int64
- func (*PlacementTable) ProtoMessage()
- func (x *PlacementTable) ProtoReflect() protoreflect.Message
- func (x *PlacementTable) Reset()
- func (x *PlacementTable) String() string
- type PlacementTables
- func (*PlacementTables) Descriptor() ([]byte, []int)deprecated
- func (x *PlacementTables) GetEntries() map[string]*PlacementTable
- func (x *PlacementTables) GetVersion() string
- func (*PlacementTables) ProtoMessage()
- func (x *PlacementTables) ProtoReflect() protoreflect.Message
- func (x *PlacementTables) Reset()
- func (x *PlacementTables) String() string
- type Placement_ReportDaprStatusClient
- type Placement_ReportDaprStatusServer
- type UnimplementedPlacementServer
- type UnsafePlacementServer
Constants ¶
This section is empty.
Variables ¶
var File_dapr_proto_placement_v1_placement_proto protoreflect.FileDescriptor
var Placement_ServiceDesc = grpc.ServiceDesc{ ServiceName: "dapr.proto.placement.v1.Placement", HandlerType: (*PlacementServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "ReportDaprStatus", Handler: _Placement_ReportDaprStatus_Handler, ServerStreams: true, ClientStreams: true, }, }, Metadata: "dapr/proto/placement/v1/placement.proto", }
Placement_ServiceDesc is the grpc.ServiceDesc for Placement service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterPlacementServer ¶
func RegisterPlacementServer(s grpc.ServiceRegistrar, srv PlacementServer)
Types ¶
type Host ¶
type Host struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Port int64 `protobuf:"varint,2,opt,name=port,proto3" json:"port,omitempty"` Load int64 `protobuf:"varint,3,opt,name=load,proto3" json:"load,omitempty"` Entities []string `protobuf:"bytes,4,rep,name=entities,proto3" json:"entities,omitempty"` Id string `protobuf:"bytes,5,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*Host) Descriptor
deprecated
func (*Host) GetEntities ¶
func (*Host) ProtoMessage ¶
func (*Host) ProtoMessage()
func (*Host) ProtoReflect ¶
func (x *Host) ProtoReflect() protoreflect.Message
type PlacementClient ¶
type PlacementClient interface {
ReportDaprStatus(ctx context.Context, opts ...grpc.CallOption) (Placement_ReportDaprStatusClient, error)
}
PlacementClient is the client API for Placement service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewPlacementClient ¶
func NewPlacementClient(cc grpc.ClientConnInterface) PlacementClient
type PlacementOrder ¶
type PlacementOrder struct { Tables *PlacementTables `protobuf:"bytes,1,opt,name=tables,proto3" json:"tables,omitempty"` Operation string `protobuf:"bytes,2,opt,name=operation,proto3" json:"operation,omitempty"` // contains filtered or unexported fields }
func (*PlacementOrder) Descriptor
deprecated
func (*PlacementOrder) Descriptor() ([]byte, []int)
Deprecated: Use PlacementOrder.ProtoReflect.Descriptor instead.
func (*PlacementOrder) GetOperation ¶
func (x *PlacementOrder) GetOperation() string
func (*PlacementOrder) GetTables ¶
func (x *PlacementOrder) GetTables() *PlacementTables
func (*PlacementOrder) ProtoMessage ¶
func (*PlacementOrder) ProtoMessage()
func (*PlacementOrder) ProtoReflect ¶
func (x *PlacementOrder) ProtoReflect() protoreflect.Message
func (*PlacementOrder) Reset ¶
func (x *PlacementOrder) Reset()
func (*PlacementOrder) String ¶
func (x *PlacementOrder) String() string
type PlacementServer ¶
type PlacementServer interface {
ReportDaprStatus(Placement_ReportDaprStatusServer) error
}
PlacementServer is the server API for Placement service. All implementations should embed UnimplementedPlacementServer for forward compatibility
type PlacementTable ¶
type PlacementTable struct { Hosts map[uint64]string `` /* 152-byte string literal not displayed */ SortedSet []uint64 `protobuf:"varint,2,rep,packed,name=sorted_set,json=sortedSet,proto3" json:"sorted_set,omitempty"` LoadMap map[string]*Host `` /* 170-byte string literal not displayed */ TotalLoad int64 `protobuf:"varint,4,opt,name=total_load,json=totalLoad,proto3" json:"total_load,omitempty"` // contains filtered or unexported fields }
func (*PlacementTable) Descriptor
deprecated
func (*PlacementTable) Descriptor() ([]byte, []int)
Deprecated: Use PlacementTable.ProtoReflect.Descriptor instead.
func (*PlacementTable) GetHosts ¶
func (x *PlacementTable) GetHosts() map[uint64]string
func (*PlacementTable) GetLoadMap ¶
func (x *PlacementTable) GetLoadMap() map[string]*Host
func (*PlacementTable) GetSortedSet ¶
func (x *PlacementTable) GetSortedSet() []uint64
func (*PlacementTable) GetTotalLoad ¶
func (x *PlacementTable) GetTotalLoad() int64
func (*PlacementTable) ProtoMessage ¶
func (*PlacementTable) ProtoMessage()
func (*PlacementTable) ProtoReflect ¶
func (x *PlacementTable) ProtoReflect() protoreflect.Message
func (*PlacementTable) Reset ¶
func (x *PlacementTable) Reset()
func (*PlacementTable) String ¶
func (x *PlacementTable) String() string
type PlacementTables ¶
type PlacementTables struct { Entries map[string]*PlacementTable `` /* 155-byte string literal not displayed */ Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"` // contains filtered or unexported fields }
func (*PlacementTables) Descriptor
deprecated
func (*PlacementTables) Descriptor() ([]byte, []int)
Deprecated: Use PlacementTables.ProtoReflect.Descriptor instead.
func (*PlacementTables) GetEntries ¶
func (x *PlacementTables) GetEntries() map[string]*PlacementTable
func (*PlacementTables) GetVersion ¶
func (x *PlacementTables) GetVersion() string
func (*PlacementTables) ProtoMessage ¶
func (*PlacementTables) ProtoMessage()
func (*PlacementTables) ProtoReflect ¶
func (x *PlacementTables) ProtoReflect() protoreflect.Message
func (*PlacementTables) Reset ¶
func (x *PlacementTables) Reset()
func (*PlacementTables) String ¶
func (x *PlacementTables) String() string
type Placement_ReportDaprStatusClient ¶
type Placement_ReportDaprStatusClient interface { Send(*Host) error Recv() (*PlacementOrder, error) grpc.ClientStream }
type Placement_ReportDaprStatusServer ¶
type Placement_ReportDaprStatusServer interface { Send(*PlacementOrder) error Recv() (*Host, error) grpc.ServerStream }
type UnimplementedPlacementServer ¶
type UnimplementedPlacementServer struct { }
UnimplementedPlacementServer should be embedded to have forward compatible implementations.
func (UnimplementedPlacementServer) ReportDaprStatus ¶
func (UnimplementedPlacementServer) ReportDaprStatus(Placement_ReportDaprStatusServer) error
type UnsafePlacementServer ¶
type UnsafePlacementServer interface {
// contains filtered or unexported methods
}
UnsafePlacementServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PlacementServer will result in compilation errors.