Documentation
¶
Overview ¶
Package proto is generated by protoactor-go/protoc-gen-gograin@0.1.0
Index ¶
- Variables
- func AggregateFactory(factory func() Aggregate)
- func GetAggregateKind(opts ...actor.PropsOption) *cluster.Kind
- func GetProjectorKind(opts ...actor.PropsOption) *cluster.Kind
- func NewAggregateKind(factory func() Aggregate, timeout time.Duration, opts ...actor.PropsOption) *cluster.Kind
- func NewProjectorKind(factory func() Projector, timeout time.Duration, opts ...actor.PropsOption) *cluster.Kind
- func ProjectorFactory(factory func() Projector)
- func SetLogLevel(level logmod.Level)
- type Aggregate
- type AggregateActor
- type AggregateGrainClient
- type CommandRequest
- func (*CommandRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CommandRequest) GetData() []byte
- func (x *CommandRequest) GetName() string
- func (*CommandRequest) ProtoMessage()
- func (x *CommandRequest) ProtoReflect() protoreflect.Message
- func (x *CommandRequest) Reset()
- func (x *CommandRequest) String() string
- type CommandResponse
- type Projector
- type ProjectorActor
- type ProjectorGrainClient
- type StartRequest
- type StartResponse
Constants ¶
This section is empty.
Variables ¶
var File_revent_proto protoreflect.FileDescriptor
Functions ¶
func AggregateFactory ¶
func AggregateFactory(factory func() Aggregate)
AggregateFactory produces a Aggregate
func GetAggregateKind ¶
func GetAggregateKind(opts ...actor.PropsOption) *cluster.Kind
GetAggregateKind instantiates a new cluster.Kind for Aggregate
func GetProjectorKind ¶
func GetProjectorKind(opts ...actor.PropsOption) *cluster.Kind
GetProjectorKind instantiates a new cluster.Kind for Projector
func NewAggregateKind ¶
func NewAggregateKind(factory func() Aggregate, timeout time.Duration, opts ...actor.PropsOption) *cluster.Kind
GetAggregateKind instantiates a new cluster.Kind for Aggregate
func NewProjectorKind ¶
func NewProjectorKind(factory func() Projector, timeout time.Duration, opts ...actor.PropsOption) *cluster.Kind
GetProjectorKind instantiates a new cluster.Kind for Projector
func ProjectorFactory ¶
func ProjectorFactory(factory func() Projector)
ProjectorFactory produces a Projector
Types ¶
type Aggregate ¶
type Aggregate interface { Init(ctx cluster.GrainContext) Terminate(ctx cluster.GrainContext) ReceiveDefault(ctx cluster.GrainContext) Handle(*CommandRequest, cluster.GrainContext) (*CommandResponse, error) }
Aggregate interfaces the services available to the Aggregate
type AggregateActor ¶
AggregateActor represents the actor structure
func (*AggregateActor) Receive ¶
func (a *AggregateActor) Receive(ctx actor.Context)
Receive ensures the lifecycle of the actor for the received message
type AggregateGrainClient ¶
type AggregateGrainClient struct { Identity string // contains filtered or unexported fields }
AggregateGrainClient holds the base data for the AggregateGrain
func GetAggregateGrainClient ¶
func GetAggregateGrainClient(c *cluster.Cluster, id string) *AggregateGrainClient
GetAggregateGrainClient instantiates a new AggregateGrainClient with given Identity
func (*AggregateGrainClient) Handle ¶
func (g *AggregateGrainClient) Handle(r *CommandRequest, opts ...cluster.GrainCallOption) (*CommandResponse, error)
Handle requests the execution on to the cluster with CallOptions
type CommandRequest ¶
type CommandRequest struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` // contains filtered or unexported fields }
func (*CommandRequest) Descriptor
deprecated
func (*CommandRequest) Descriptor() ([]byte, []int)
Deprecated: Use CommandRequest.ProtoReflect.Descriptor instead.
func (*CommandRequest) GetData ¶
func (x *CommandRequest) GetData() []byte
func (*CommandRequest) GetName ¶
func (x *CommandRequest) GetName() string
func (*CommandRequest) ProtoMessage ¶
func (*CommandRequest) ProtoMessage()
func (*CommandRequest) ProtoReflect ¶
func (x *CommandRequest) ProtoReflect() protoreflect.Message
func (*CommandRequest) Reset ¶
func (x *CommandRequest) Reset()
func (*CommandRequest) String ¶
func (x *CommandRequest) String() string
type CommandResponse ¶
type CommandResponse struct {
// contains filtered or unexported fields
}
func (*CommandResponse) Descriptor
deprecated
func (*CommandResponse) Descriptor() ([]byte, []int)
Deprecated: Use CommandResponse.ProtoReflect.Descriptor instead.
func (*CommandResponse) ProtoMessage ¶
func (*CommandResponse) ProtoMessage()
func (*CommandResponse) ProtoReflect ¶
func (x *CommandResponse) ProtoReflect() protoreflect.Message
func (*CommandResponse) Reset ¶
func (x *CommandResponse) Reset()
func (*CommandResponse) String ¶
func (x *CommandResponse) String() string
type Projector ¶
type Projector interface { Init(ctx cluster.GrainContext) Terminate(ctx cluster.GrainContext) ReceiveDefault(ctx cluster.GrainContext) Start(*StartRequest, cluster.GrainContext) (*StartResponse, error) }
Projector interfaces the services available to the Projector
type ProjectorActor ¶
ProjectorActor represents the actor structure
func (*ProjectorActor) Receive ¶
func (a *ProjectorActor) Receive(ctx actor.Context)
Receive ensures the lifecycle of the actor for the received message
type ProjectorGrainClient ¶
type ProjectorGrainClient struct { Identity string // contains filtered or unexported fields }
ProjectorGrainClient holds the base data for the ProjectorGrain
func GetProjectorGrainClient ¶
func GetProjectorGrainClient(c *cluster.Cluster, id string) *ProjectorGrainClient
GetProjectorGrainClient instantiates a new ProjectorGrainClient with given Identity
func (*ProjectorGrainClient) Start ¶
func (g *ProjectorGrainClient) Start(r *StartRequest, opts ...cluster.GrainCallOption) (*StartResponse, error)
Start requests the execution on to the cluster with CallOptions
type StartRequest ¶
type StartRequest struct { ProjectionName string `protobuf:"bytes,1,opt,name=projectionName,proto3" json:"projectionName,omitempty"` // contains filtered or unexported fields }
func (*StartRequest) Descriptor
deprecated
func (*StartRequest) Descriptor() ([]byte, []int)
Deprecated: Use StartRequest.ProtoReflect.Descriptor instead.
func (*StartRequest) GetProjectionName ¶
func (x *StartRequest) GetProjectionName() string
func (*StartRequest) ProtoMessage ¶
func (*StartRequest) ProtoMessage()
func (*StartRequest) ProtoReflect ¶
func (x *StartRequest) ProtoReflect() protoreflect.Message
func (*StartRequest) Reset ¶
func (x *StartRequest) Reset()
func (*StartRequest) String ¶
func (x *StartRequest) String() string
type StartResponse ¶
type StartResponse struct {
// contains filtered or unexported fields
}
func (*StartResponse) Descriptor
deprecated
func (*StartResponse) Descriptor() ([]byte, []int)
Deprecated: Use StartResponse.ProtoReflect.Descriptor instead.
func (*StartResponse) ProtoMessage ¶
func (*StartResponse) ProtoMessage()
func (*StartResponse) ProtoReflect ¶
func (x *StartResponse) ProtoReflect() protoreflect.Message
func (*StartResponse) Reset ¶
func (x *StartResponse) Reset()
func (*StartResponse) String ¶
func (x *StartResponse) String() string