Documentation ¶
Index ¶
- type ClusterIDs
- type CronScript
- type HandleNATSMessageFunc
- type Server
- func (s *Server) CreateScript(ctx context.Context, req *cronscriptpb.CreateScriptRequest) (*cronscriptpb.CreateScriptResponse, error)
- func (s *Server) DeleteScript(ctx context.Context, req *cronscriptpb.DeleteScriptRequest) (*cronscriptpb.DeleteScriptResponse, error)
- func (s *Server) GetScript(ctx context.Context, req *cronscriptpb.GetScriptRequest) (*cronscriptpb.GetScriptResponse, error)
- func (s *Server) GetScripts(ctx context.Context, req *cronscriptpb.GetScriptsRequest) (*cronscriptpb.GetScriptsResponse, error)
- func (s *Server) HandleChecksumRequest(msg *cvmsgspb.V2CMessage)
- func (s *Server) HandleScriptsRequest(msg *cvmsgspb.V2CMessage)
- func (s *Server) Stop()
- func (s *Server) UpdateScript(ctx context.Context, req *cronscriptpb.UpdateScriptRequest) (*cronscriptpb.UpdateScriptResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClusterIDs ¶
ClusterIDs represents an array of cluster IDs.
func (*ClusterIDs) Scan ¶
func (p *ClusterIDs) Scan(src interface{}) error
Scan Scans the sqlx database type ([]bytes) into the ClusterIds type.
type CronScript ¶
type CronScript struct { ID uuid.UUID `db:"id"` OrgID uuid.UUID `db:"org_id"` Script string `db:"script"` ClusterIDs ClusterIDs `db:"cluster_ids"` ConfigStr string `db:"configs"` Enabled bool `db:"enabled"` FrequencyS int64 `db:"frequency_s"` }
CronScript contains metadata about a regularly scheduled script.
type HandleNATSMessageFunc ¶
type HandleNATSMessageFunc func(*cvmsgspb.V2CMessage)
HandleNATSMessageFunc is the signature for a NATS message handler.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is a bridge implementation of the pluginService.
func (*Server) CreateScript ¶
func (s *Server) CreateScript(ctx context.Context, req *cronscriptpb.CreateScriptRequest) (*cronscriptpb.CreateScriptResponse, error)
CreateScript creates a cron script.
func (*Server) DeleteScript ¶
func (s *Server) DeleteScript(ctx context.Context, req *cronscriptpb.DeleteScriptRequest) (*cronscriptpb.DeleteScriptResponse, error)
DeleteScript deletes a cron script.
func (*Server) GetScript ¶
func (s *Server) GetScript(ctx context.Context, req *cronscriptpb.GetScriptRequest) (*cronscriptpb.GetScriptResponse, error)
GetScript gets a script stored in the cron script service.
func (*Server) GetScripts ¶
func (s *Server) GetScripts(ctx context.Context, req *cronscriptpb.GetScriptsRequest) (*cronscriptpb.GetScriptsResponse, error)
GetScripts gets scripts stored in the cron script service, given a set of IDs.
func (*Server) HandleChecksumRequest ¶
func (s *Server) HandleChecksumRequest(msg *cvmsgspb.V2CMessage)
HandleChecksumRequest handles incoming requests for cronscript checksums.
func (*Server) HandleScriptsRequest ¶
func (s *Server) HandleScriptsRequest(msg *cvmsgspb.V2CMessage)
HandleScriptsRequest handles incoming requests for cron scripts registered to the given vizier.
func (*Server) UpdateScript ¶
func (s *Server) UpdateScript(ctx context.Context, req *cronscriptpb.UpdateScriptRequest) (*cronscriptpb.UpdateScriptResponse, error)
UpdateScript updates an existing cron script.