Documentation
¶
Index ¶
- Constants
- func NewWorkflowServiceHandler(svc WorkflowServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
- type UnimplementedWorkflowServiceHandler
- func (UnimplementedWorkflowServiceHandler) BulkTriggerWorkflow(context.Context, *contracts.BulkTriggerWorkflowRequest) (*contracts.BulkTriggerWorkflowResponse, error)
- func (UnimplementedWorkflowServiceHandler) PutRateLimit(context.Context, *contracts.PutRateLimitRequest) (*contracts.PutRateLimitResponse, error)
- func (UnimplementedWorkflowServiceHandler) PutWorkflow(context.Context, *contracts.PutWorkflowRequest) (*contracts.WorkflowVersion, error)
- func (UnimplementedWorkflowServiceHandler) ScheduleWorkflow(context.Context, *contracts.ScheduleWorkflowRequest) (*contracts.WorkflowVersion, error)
- func (UnimplementedWorkflowServiceHandler) TriggerWorkflow(context.Context, *v1.TriggerWorkflowRequest) (*contracts.TriggerWorkflowResponse, error)
- type WorkflowServiceClient
- type WorkflowServiceHandler
Constants ¶
const ( // WorkflowServicePutWorkflowProcedure is the fully-qualified name of the WorkflowService's // PutWorkflow RPC. WorkflowServicePutWorkflowProcedure = "/WorkflowService/PutWorkflow" // WorkflowServiceScheduleWorkflowProcedure is the fully-qualified name of the WorkflowService's // ScheduleWorkflow RPC. WorkflowServiceScheduleWorkflowProcedure = "/WorkflowService/ScheduleWorkflow" // WorkflowServiceTriggerWorkflowProcedure is the fully-qualified name of the WorkflowService's // TriggerWorkflow RPC. WorkflowServiceTriggerWorkflowProcedure = "/WorkflowService/TriggerWorkflow" // WorkflowServiceBulkTriggerWorkflowProcedure is the fully-qualified name of the WorkflowService's // BulkTriggerWorkflow RPC. WorkflowServiceBulkTriggerWorkflowProcedure = "/WorkflowService/BulkTriggerWorkflow" // WorkflowServicePutRateLimitProcedure is the fully-qualified name of the WorkflowService's // PutRateLimit RPC. WorkflowServicePutRateLimitProcedure = "/WorkflowService/PutRateLimit" )
These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.
Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.
const (
// WorkflowServiceName is the fully-qualified name of the WorkflowService service.
WorkflowServiceName = "WorkflowService"
)
Variables ¶
This section is empty.
Functions ¶
func NewWorkflowServiceHandler ¶
func NewWorkflowServiceHandler(svc WorkflowServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
NewWorkflowServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.
By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.
Types ¶
type UnimplementedWorkflowServiceHandler ¶
type UnimplementedWorkflowServiceHandler struct{}
UnimplementedWorkflowServiceHandler returns CodeUnimplemented from all methods.
func (UnimplementedWorkflowServiceHandler) BulkTriggerWorkflow ¶
func (UnimplementedWorkflowServiceHandler) BulkTriggerWorkflow(context.Context, *contracts.BulkTriggerWorkflowRequest) (*contracts.BulkTriggerWorkflowResponse, error)
func (UnimplementedWorkflowServiceHandler) PutRateLimit ¶
func (UnimplementedWorkflowServiceHandler) PutRateLimit(context.Context, *contracts.PutRateLimitRequest) (*contracts.PutRateLimitResponse, error)
func (UnimplementedWorkflowServiceHandler) PutWorkflow ¶
func (UnimplementedWorkflowServiceHandler) PutWorkflow(context.Context, *contracts.PutWorkflowRequest) (*contracts.WorkflowVersion, error)
func (UnimplementedWorkflowServiceHandler) ScheduleWorkflow ¶
func (UnimplementedWorkflowServiceHandler) ScheduleWorkflow(context.Context, *contracts.ScheduleWorkflowRequest) (*contracts.WorkflowVersion, error)
func (UnimplementedWorkflowServiceHandler) TriggerWorkflow ¶
func (UnimplementedWorkflowServiceHandler) TriggerWorkflow(context.Context, *v1.TriggerWorkflowRequest) (*contracts.TriggerWorkflowResponse, error)
type WorkflowServiceClient ¶
type WorkflowServiceClient interface {
PutWorkflow(context.Context, *contracts.PutWorkflowRequest) (*contracts.WorkflowVersion, error)
ScheduleWorkflow(context.Context, *contracts.ScheduleWorkflowRequest) (*contracts.WorkflowVersion, error)
TriggerWorkflow(context.Context, *v1.TriggerWorkflowRequest) (*contracts.TriggerWorkflowResponse, error)
BulkTriggerWorkflow(context.Context, *contracts.BulkTriggerWorkflowRequest) (*contracts.BulkTriggerWorkflowResponse, error)
PutRateLimit(context.Context, *contracts.PutRateLimitRequest) (*contracts.PutRateLimitResponse, error)
}
WorkflowServiceClient is a client for the WorkflowService service.
func NewWorkflowServiceClient ¶
func NewWorkflowServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) WorkflowServiceClient
NewWorkflowServiceClient constructs a client for the WorkflowService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.
The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).
type WorkflowServiceHandler ¶
type WorkflowServiceHandler interface {
PutWorkflow(context.Context, *contracts.PutWorkflowRequest) (*contracts.WorkflowVersion, error)
ScheduleWorkflow(context.Context, *contracts.ScheduleWorkflowRequest) (*contracts.WorkflowVersion, error)
TriggerWorkflow(context.Context, *v1.TriggerWorkflowRequest) (*contracts.TriggerWorkflowResponse, error)
BulkTriggerWorkflow(context.Context, *contracts.BulkTriggerWorkflowRequest) (*contracts.BulkTriggerWorkflowResponse, error)
PutRateLimit(context.Context, *contracts.PutRateLimitRequest) (*contracts.PutRateLimitResponse, error)
}
WorkflowServiceHandler is an implementation of the WorkflowService service.