pps

package
v2.8.0-nightly.20231020 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsJobFinishedErr

func IsJobFinishedErr(err error) bool

IsJobFinishedErr returns true if 'err' has an error message that matches ErrJobFinished

func IsPipelineNotFoundErr

func IsPipelineNotFoundErr(err error) bool

IsPipelineNotFoundErr returns true if 'err' has an error message that matches ErrJobFinished

Types

type APIServer

type APIServer interface {
	pps_client.APIServer

	NewPropagater(*txncontext.TransactionContext) txncontext.PpsPropagater
	NewJobStopper(*txncontext.TransactionContext) txncontext.PpsJobStopper
	NewJobFinisher(*txncontext.TransactionContext) txncontext.PpsJobFinisher

	StopJobInTransaction(context.Context, *txncontext.TransactionContext, *pps_client.StopJobRequest) error
	UpdateJobStateInTransaction(context.Context, *txncontext.TransactionContext, *pps_client.UpdateJobStateRequest) error
	CreatePipelineInTransaction(context.Context, *txncontext.TransactionContext, *pps_client.CreatePipelineTransaction) error
	// InspectPipelineInTransaction returns the pipeline information for a
	// pipeline.  Note that the pipeline name may include ancestry syntax.
	InspectPipelineInTransaction(context.Context, *txncontext.TransactionContext, *pps.Pipeline) (*pps_client.PipelineInfo, error)
	ActivateAuthInTransaction(context.Context, *txncontext.TransactionContext, *pps_client.ActivateAuthRequest) (*pps_client.ActivateAuthResponse, error)
	CreateDetPipelineSideEffects(context.Context, *pps.Pipeline, []string) error
}

APIServer is the internal interface for other services to call this one. This includes all the public RPC methods and additional internal-only methods for use within pachd. These methods *do not* check that a user is authorized unless otherwise noted.

type ErrJobFinished

type ErrJobFinished struct {
	Job *pps.Job
}

ErrJobFinished represents a finished job error.

func (ErrJobFinished) Error

func (e ErrJobFinished) Error() string

type ErrPipelineAlreadyExists

type ErrPipelineAlreadyExists struct {
	Pipeline *pps.Pipeline
}

func (ErrPipelineAlreadyExists) Error

func (e ErrPipelineAlreadyExists) Error() string

func (ErrPipelineAlreadyExists) GRPCStatus

func (e ErrPipelineAlreadyExists) GRPCStatus() *status.Status

type ErrPipelineNotFound

type ErrPipelineNotFound struct {
	Pipeline *pps.Pipeline
}

func (ErrPipelineNotFound) Error

func (e ErrPipelineNotFound) Error() string

func (ErrPipelineNotFound) GRPCStatus

func (e ErrPipelineNotFound) GRPCStatus() *status.Status

type Hasher

type Hasher struct {
	JobModulus      uint64
	PipelineModulus uint64
}

A Hasher represents a job/pipeline hasher.

func NewHasher

func NewHasher(jobModulus uint64, pipelineModulus uint64) *Hasher

NewHasher creates a hasher.

func (*Hasher) HashJob

func (s *Hasher) HashJob(jobID string) uint64

HashJob computes and returns the hash of a job.

func (*Hasher) HashPipeline

func (s *Hasher) HashPipeline(pipelineName string) uint64

HashPipeline computes and returns the hash of a pipeline.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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