cron

package
v0.0.0-...-e560ebb Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2021 License: BSD-3-Clause Imports: 13 Imported by: 0

Documentation

Overview

Package cron contains the cron trigger API.

Index

Constants

This section is empty.

Variables

View Source
var File_infra_unifiedfleet_api_v1_cron_cron_proto protoreflect.FileDescriptor

Functions

func FileDescriptorSet

func FileDescriptorSet() *descriptorpb.FileDescriptorSet

FileDescriptorSet returns a descriptor set for this proto package, which includes all defined services, and all transitive dependencies.

Will not return nil.

Do NOT modify the returned descriptor.

func RegisterCronServer

func RegisterCronServer(s prpc.Registrar, srv CronServer)

Types

type CronClient

type CronClient interface {
	TriggerCronJob(ctx context.Context, in *TriggerCronJobReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
}

CronClient is the client API for Cron service.

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

func NewCronClient

func NewCronClient(cc grpc.ClientConnInterface) CronClient

func NewCronPRPCClient

func NewCronPRPCClient(client *prpc.Client) CronClient

type CronServer

type CronServer interface {
	TriggerCronJob(context.Context, *TriggerCronJobReq) (*emptypb.Empty, error)
}

CronServer is the server API for Cron service.

type DecoratedCron

type DecoratedCron struct {
	// Service is the service to decorate.
	Service CronServer
	// Prelude is called for each method before forwarding the call to Service.
	// If Prelude returns an error, then the call is skipped and the error is
	// processed via the Postlude (if one is defined), or it is returned directly.
	Prelude func(ctx context.Context, methodName string, req proto.Message) (context.Context, error)
	// Postlude is called for each method after Service has processed the call, or
	// after the Prelude has returned an error. This takes the the Service's
	// response proto (which may be nil) and/or any error. The decorated
	// service will return the response (possibly mutated) and error that Postlude
	// returns.
	Postlude func(ctx context.Context, methodName string, rsp proto.Message, err error) error
}

func (*DecoratedCron) TriggerCronJob

func (s *DecoratedCron) TriggerCronJob(ctx context.Context, req *TriggerCronJobReq) (rsp *emptypb.Empty, err error)

type TriggerCronJobReq

type TriggerCronJobReq struct {
	JobName string `protobuf:"bytes,1,opt,name=job_name,json=jobName,proto3" json:"job_name,omitempty"`
	// contains filtered or unexported fields
}

func (*TriggerCronJobReq) Descriptor deprecated

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

Deprecated: Use TriggerCronJobReq.ProtoReflect.Descriptor instead.

func (*TriggerCronJobReq) GetJobName

func (x *TriggerCronJobReq) GetJobName() string

func (*TriggerCronJobReq) ProtoMessage

func (*TriggerCronJobReq) ProtoMessage()

func (*TriggerCronJobReq) ProtoReflect

func (x *TriggerCronJobReq) ProtoReflect() protoreflect.Message

func (*TriggerCronJobReq) Reset

func (x *TriggerCronJobReq) Reset()

func (*TriggerCronJobReq) String

func (x *TriggerCronJobReq) String() string

func (*TriggerCronJobReq) Validate

func (req *TriggerCronJobReq) Validate() error

type UnimplementedCronServer

type UnimplementedCronServer struct {
}

UnimplementedCronServer can be embedded to have forward compatible implementations.

func (*UnimplementedCronServer) TriggerCronJob

Jump to

Keyboard shortcuts

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