client

package
v2.7.0-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2023 License: Apache-2.0 Imports: 58 Imported by: 7

Documentation

Index

Constants

View Source
const (
	// MaxListItemsLog specifies the maximum number of items we log in response to a List* API
	MaxListItemsLog = 10
	// StorageSecretName is the name of the Kubernetes secret in which storage credentials are stored.
	StorageSecretName = "pachyderm-storage-secret"
	// PostgresSecretName is the name of the secret containing the postgres password
	// It must match the secret passed to pachd here: etc/helm/pachyderm/templates/pachd/deployment.yaml
	PostgresSecretName = "postgres"
	// PachctlSecretName is the name of the Kubernetes secret in which
	// pachctl credentials are stored.
	PachctlSecretName = "pachyderm-pachctl-secret"
)
View Source
const (
	// PPSEtcdPrefixEnv is the environment variable that specifies the etcd
	// prefix that PPS uses.
	PPSEtcdPrefixEnv = "PPS_ETCD_PREFIX"
	// PPSWorkerIPEnv is the environment variable that a worker can use to
	// see its own IP.  The IP address is made available through the
	// Kubernetes downward API.
	PPSWorkerIPEnv = "PPS_WORKER_IP"
	// PPSPodNameEnv is the environment variable that a pod can use to
	// see its own name.  The pod name is made available through the
	// Kubernetes downward API.
	PPSPodNameEnv = "PPS_POD_NAME"
	// PPSProjectNameEnv is the env var that sets the name of the project
	// that the workers are running.
	PPSProjectNameEnv = "PPS_PROJECT_NAME"
	// PPSPipelineNameEnv is the env var that sets the name of the pipeline
	// that the workers are running.
	PPSPipelineNameEnv = "PPS_PIPELINE_NAME"
	// PPSJobIDEnv is the env var that sets the ID of the job that the
	// workers are running (if the workers belong to an orphan job, rather than a
	// pipeline).
	PPSJobIDEnv = "PPS_JOB_ID"
	// PPSSpecCommitEnv is the namespace in which pachyderm is deployed
	PPSSpecCommitEnv = "PPS_SPEC_COMMIT"
	// PPSInputPrefix is the prefix of the path where datums are downloaded
	// to.  A datum of an input named `XXX` is downloaded to `/pfs/XXX/`.
	PPSInputPrefix = "/pfs"
	// PPSScratchSpace is where pps workers store data while it's waiting to be
	// processed.
	PPSScratchSpace = ".scratch"
	// PPSWorkerPortEnv is environment variable name for the port that workers
	// use for their gRPC server
	PPSWorkerPortEnv = "PPS_WORKER_GRPC_PORT"
	// PPSWorkerVolume is the name of the volume in which workers store
	// data.
	PPSWorkerVolume = "pachyderm-worker"
	// PPSWorkerUserContainerName is the name of the container that runs
	// the user code to process data.
	PPSWorkerUserContainerName = "user"
	// PPSWorkerSidecarContainerName is the name of the sidecar container
	// that runs alongside of each worker container.
	PPSWorkerSidecarContainerName = "storage"
	// GCGenerationKey is the etcd key that stores a counter that the
	// GC utility increments when it runs, so as to invalidate all cache.
	GCGenerationKey = "gc-generation"
	// JobIDEnv is an env var that is added to the environment of user pipeline
	// code and indicates the id of the job currently being run.
	JobIDEnv = "PACH_JOB_ID"
	// OutputCommitIDEnv is an env var that is added to the environment of user
	// pipelined code and indicates the id of the output commit.
	OutputCommitIDEnv = "PACH_OUTPUT_COMMIT_ID"
	// DatumIDEnv is an env var that is added to the environment of user
	// pipelined code and indicates the id of the datum.
	DatumIDEnv = "PACH_DATUM_ID"
	// PeerPortEnv is the env var that sets a custom peer port
	PeerPortEnv = "PEER_PORT"

	ReprocessSpecUntilSuccess = "until_success"
	ReprocessSpecEveryJob     = "every_job"
)
View Source
const DefaultDialTimeout = 30 * time.Second

DefaultDialTimeout is the max amount of time APIClient.connect() will wait for a connection to be established unless overridden by WithDialTimeout()

View Source
const DefaultMaxConcurrentStreams = 100

DefaultMaxConcurrentStreams defines the max number of Putfiles or Getfiles happening simultaneously

View Source
const DefaultTTL = 10 * time.Minute

DefaultTTL is the default time-to-live for a temporary fileset.

View Source
const FileSetsRepoName = "__filesets__"

FileSetsRepoName is the repo name used to access filesets as virtual commits.

Variables

This section is empty.

Functions

func DefaultDialOptions

func DefaultDialOptions() []grpc.DialOption

DefaultDialOptions is a helper returning a slice of grpc.Dial options such that grpc.Dial() is synchronous: the call doesn't return until the connection has been established and it's safe to send RPCs

func GetDatumTotalTime

func GetDatumTotalTime(s *pps.ProcessStats) time.Duration

GetDatumTotalTime sums the timing stats from a DatumInfo

func GetTransaction

func GetTransaction(ctx context.Context) (*transaction.Transaction, error)

GetTransaction (should be run from the server-side) loads the active transaction from the grpc metadata and returns the associated transaction object - or `nil` if no transaction is set.

func GetUserMachineAddr

func GetUserMachineAddr(context *config.Context) (addr *grpcutil.PachdAddress, err error)

func NewBranch deprecated

func NewBranch(repoName string, branchName string) *pfs.Branch

NewBranch creates a pfs.Branch

Deprecated: use NewProjectBranch instead.

func NewCommit deprecated

func NewCommit(repoName, branchName, commitID string) *pfs.Commit

NewCommit creates a pfs.Commit.

Deprecated: use NewProjectCommit instead.

func NewCommitSet

func NewCommitSet(id string) *pfs.CommitSet

NewCommitSet creates a pfs.CommitSet

func NewCronInput

func NewCronInput(name string, spec string) *pps.Input

NewCronInput returns an input which will trigger based on a timed schedule. It uses cron syntax to specify the schedule. The input will be exposed to jobs as `/pfs/<name>/<timestamp>`. The timestamp uses the RFC 3339 format, e.g. `2006-01-02T15:04:05Z07:00`. It only takes required options.

func NewCronInputOpts

func NewCronInputOpts(name string, repo string, spec string, overwrite bool, start *types.Timestamp) *pps.Input

NewCronInputOpts returns an input which will trigger based on a timed schedule. It uses cron syntax to specify the schedule. The input will be exposed to jobs as `/pfs/<name>/<timestamp>`. The timestamp uses the RFC 3339 format, e.g. `2006-01-02T15:04:05Z07:00`. It includes all the options.

func NewCrossInput

func NewCrossInput(input ...*pps.Input) *pps.Input

NewCrossInput returns an input which is the cross product of other inputs. That means that all combination of datums will be seen by the job / pipeline.

func NewFile deprecated

func NewFile(repoName, branchName, commitID, path string) *pfs.File

NewFile creates a pfs.File.

Deprecated: use NewProjectFile instead.

func NewGroupInput

func NewGroupInput(input ...*pps.Input) *pps.Input

NewGroupInput returns an input which groups the inputs by the GroupBy pattern. That means that it will return a datum for each group of input datums matching a particular GroupBy pattern

func NewJob deprecated

func NewJob(pipelineName, jobID string) *pps.Job

NewJob creates a pps.Job.

Deprecated: use NewProjectJob instead.

func NewJobInput deprecated

func NewJobInput(repoName, branchName, commitID, glob string) *pps.JobInput

NewJobInput creates a pps.JobInput.

Deprecated: use NewProjectJobInput instead.

func NewJobSet

func NewJobSet(id string) *pps.JobSet

NewJobSet creates a pps.JobSet.

func NewJoinInput

func NewJoinInput(input ...*pps.Input) *pps.Input

NewJoinInput returns an input which is the join of other inputs. That means that all combination of datums which match on `joinOn` will be seen by the job / pipeline.

func NewPFSInput deprecated

func NewPFSInput(repo, glob string) *pps.Input

NewPFSInput returns a new PFS input. It only includes required options.

Deprecated: use NewProjectPFSInput instead.

func NewPFSInputOpts deprecated

func NewPFSInputOpts(name, repo, branch, glob, joinOn, groupBy string, outerJoin, lazy bool, trigger *pfs.Trigger) *pps.Input

NewPFSInputOpts returns a new PFS input. It includes all options.

Deprecated: use NewProjectPFSInputOpts instead.

func NewPipeline deprecated

func NewPipeline(pipelineName string) *pps.Pipeline

NewPipeline creates a pps.Pipeline.

Deprecated: use NewProjectPipeline instead.

func NewProject

func NewProject(name string) *pfs.Project

NewProject creates a pfs.Project

func NewProjectBranch

func NewProjectBranch(projectName, repoName, branchName string) *pfs.Branch

NewProjectBranch creates a pfs.Branch in the given project & repo.

func NewProjectCommit

func NewProjectCommit(projectName, repoName, branchName, commitID string) *pfs.Commit

NewProjectCommit creates a pfs.Commit in the given project, repo & branch.

func NewProjectFile

func NewProjectFile(projectName, repoName, branchName, commitID, path string) *pfs.File

NewProjectFile creates a pfs.File.

func NewProjectJob

func NewProjectJob(projectName, pipelineName, jobID string) *pps.Job

NewProjectJob creates a pps.Job.

func NewProjectJobInput

func NewProjectJobInput(projectName, repoName, branchName, commitID, glob string) *pps.JobInput

NewProjectJobInput creates a pps.JobInput.

func NewProjectPFSInput

func NewProjectPFSInput(project, repo, glob string) *pps.Input

NewProjectPFSInput returns a new PFS input. It only includes required options.

func NewProjectPFSInputOpts

func NewProjectPFSInputOpts(name, project, repo, branch, glob, joinOn, groupBy string, outerJoin, lazy bool, trigger *pfs.Trigger) *pps.Input

NewProjectPFSInputOpts returns a new PFS input. It includes all options.

func NewProjectPipeline

func NewProjectPipeline(projectName, pipelineName string) *pps.Pipeline

NewProjectPipeline creates a pps.Pipeline.

func NewProjectRepo

func NewProjectRepo(projectName, repoName string) *pfs.Repo

func NewProjectS3PFSInput

func NewProjectS3PFSInput(name, project, repo, branch string) *pps.Input

NewProjectS3PFSInput returns a new PFS input with 'S3' set.

func NewProxyPostgresListener

func NewProxyPostgresListener(clientFactory func() (proxy.APIClient, error)) col.PostgresListener

func NewRepo deprecated

func NewRepo(repoName string) *pfs.Repo

NewRepo creates a pfs.Repo.

Deprecated: use NewProjectRepo instead.

func NewS3PFSInput deprecated

func NewS3PFSInput(name, repo, branch string) *pps.Input

NewS3PFSInput returns a new PFS input with 'S3' set.

Deprecated: use NewProjectS3PFSInput instead.

func NewSystemProjectRepo

func NewSystemProjectRepo(projectName, repoName, repoType string) *pfs.Repo

NewSystemProjectRepo creates a pfs.Repo of the given type in the given project.

func NewSystemRepo deprecated

func NewSystemRepo(repoName string, repoType string) *pfs.Repo

NewSystemRepo creates a pfs.Repo of the given type.

Deprecated: use NewSystemProjectRepo instead.

func NewUnionInput

func NewUnionInput(input ...*pps.Input) *pps.Input

NewUnionInput returns an input which is the union of other inputs. That means that all datums from any of the inputs will be seen individually by the job / pipeline.

func WithSystemCAs

func WithSystemCAs(settings *clientSettings) error

WithSystemCAs uses the system certs for client creation, if no others are provided. This is the default behaviour when the scheme is `https` or `grpcs`.

Types

type APIClient

type APIClient struct {
	PfsAPIClient
	PpsAPIClient
	AuthAPIClient
	IdentityAPIClient
	VersionAPIClient
	AdminAPIClient
	TransactionAPIClient
	DebugClient
	ProxyClient
	Enterprise enterprise.APIClient // not embedded--method name conflicts with AuthAPIClient
	License    license.APIClient
	// contains filtered or unexported fields
}

An APIClient is a wrapper around pfs, pps and block APIClients.

func NewEnterpriseClientForTest

func NewEnterpriseClientForTest() (*APIClient, error)

NewEnterpriseClientForTest constructs a new APIClient for tests. TODO(actgardner): this should probably live in testutils and accept a testing.TB

func NewEnterpriseClientOnUserMachine

func NewEnterpriseClientOnUserMachine(prefix string, options ...Option) (*APIClient, error)

NewEnterpriseClientOnUserMachine constructs a new APIClient using $HOME/.pachyderm/config if it exists. This is intended to be used in the pachctl binary to communicate with the enterprise server.

func NewEnterpriseClientOnUserMachineContext

func NewEnterpriseClientOnUserMachineContext(ctx context.Context, prefix string, options ...Option) (*APIClient, error)

NewEnterpriseClientOnUserMachineContext is like NewEnterpriseClientOnUserMachine, but accepts a context for dialing and future RPCs.

func NewForTest

func NewForTest() (*APIClient, error)

NewForTest constructs a new APIClient for tests. TODO(actgardner): this should probably live in testutils and accept a testing.TB

func NewFromPachdAddress deprecated

func NewFromPachdAddress(pachdAddress *grpcutil.PachdAddress, options ...Option) (*APIClient, error)

NewFromPachdAddress creates a new client given a parsed GRPC address.

Deprecated: Use NewFromPachdAddressContext.

func NewFromPachdAddressContext

func NewFromPachdAddressContext(ctx context.Context, pachdAddress *grpcutil.PachdAddress, options ...Option) (*APIClient, error)

NewFromPachdAddressContext is like NewFromPachdAddress, but accepts a context to use for dialing and future RPCs.

func NewFromURI deprecated

func NewFromURI(uri string, options ...Option) (*APIClient, error)

NewFromURI creates a new client given a GRPC URI.

Deprecated: Use NewFromURIContext.

func NewFromURIContext

func NewFromURIContext(ctx context.Context, uri string, options ...Option) (*APIClient, error)

NewFromURIContext creates a new client given a GRPC URI ex. grpc://test.example.com. If no scheme is specified `grpc://` is assumed. A scheme of `grpcs://` enables TLS.

func NewInCluster deprecated

func NewInCluster(options ...Option) (*APIClient, error)

NewInCluster constructs a new APIClient using env vars that Kubernetes creates. This should be used to access Pachyderm from within a Kubernetes cluster with Pachyderm running on it.

Deprecated: Use NewInClusterContext.

func NewInClusterContext

func NewInClusterContext(ctx context.Context, options ...Option) (*APIClient, error)

NewInClusterContext constructs a new APIClient using env vars that Kubernetes creates. This should be used to access Pachyderm from within a Kubernetes cluster with Pachyderm running on it.

func NewInWorker deprecated

func NewInWorker(options ...Option) (*APIClient, error)

NewInWorker constructs a new APIClient intended to be used from a worker to talk to the sidecar pachd container

Deprecated: Use NewInWorkerContext.

func NewInWorkerContext

func NewInWorkerContext(ctx context.Context, options ...Option) (*APIClient, error)

NewInWorker constructs a new APIClient intended to be used from a worker to talk to the sidecar pachd container

func NewOnUserMachine deprecated

func NewOnUserMachine(prefix string, options ...Option) (*APIClient, error)

NewOnUserMachine constructs a new APIClient using $HOME/.pachyderm/config if it exists. This is intended to be used in the pachctl binary.

Deprecated: Use NewOnUserMachineContext().

func NewOnUserMachineContext

func NewOnUserMachineContext(ctx context.Context, prefix string, options ...Option) (*APIClient, error)

NewOnUserMachineContext is like NewOnUserMachine, but accepts a context for dialing and future RPCs.

func (APIClient) AddFileSet deprecated

func (c APIClient) AddFileSet(repo, branch, commit, ID string) (retErr error)

AddFileSet adds a fileset to a commit.

Deprecated: use AddProjectFileSet instead.

func (*APIClient) AddMetadata

func (c *APIClient) AddMetadata(ctx context.Context) context.Context

AddMetadata adds necessary metadata (including authentication credentials) to the context 'ctx', preserving any metadata that is present in either the incoming or outgoing metadata of 'ctx'.

func (APIClient) AddProjectFileSet

func (c APIClient) AddProjectFileSet(project, repo, branch, commit, ID string) (retErr error)

AddProjectFileSet adds a fileset to a commit in a project.

func (*APIClient) AuthToken

func (c *APIClient) AuthToken() string

AuthToken gets the authentication token that is set for this client.

func (APIClient) Binary

func (c APIClient) Binary(filter *debug.Filter, w io.Writer) (retErr error)

Binary collects a set of binaries.

func (APIClient) ClearCommit deprecated

func (c APIClient) ClearCommit(repoName string, branchName string, commitID string) (retErr error)

ClearCommit clears the state of an open commit.

Deprecated: use ClearProjectCommit instead.

func (APIClient) ClearProjectCommit

func (c APIClient) ClearProjectCommit(projectName, repoName, branchName, commitID string) (retErr error)

ClearProjectCommit clears the state of an open commit.

func (*APIClient) ClientContextName

func (c *APIClient) ClientContextName() string

ClientContextName returns the name of the context in the client config that produced this client, or an empty string if the client was not produced from a configured client context.

func (*APIClient) Close

func (c *APIClient) Close() error

Close the connection to gRPC

func (APIClient) ComposeFileSet

func (c APIClient) ComposeFileSet(IDs []string, ttl time.Duration) (_ string, retErr error)

ComposeFileSet composes a file set from a list of file sets.

func (APIClient) CopyFile

func (c APIClient) CopyFile(dstCommit *pfs.Commit, dstPath string, srcCommit *pfs.Commit, srcPath string, opts ...CopyFileOption) error

CopyFile copies a file from one PFS location to another. It can be used on directories or regular files.

func (APIClient) CreateBranch deprecated

func (c APIClient) CreateBranch(repoName string, branchName string, commitBranch string, commitID string, provenance []*pfs.Branch) error

CreateBranch creates a new branch.

Deprecated: use CreateProjectBranch instead.

func (APIClient) CreateBranchTrigger deprecated

func (c APIClient) CreateBranchTrigger(repoName string, branchName string, commitBranch string, commitID string, trigger *pfs.Trigger) error

CreateBranchTrigger Creates a branch with a trigger. Note: triggers and provenance are mutually exclusive. See the docs on triggers to learn more about why this is.

Deprecated: use CreateProjectBranchTrigger instead.

func (APIClient) CreatePipeline deprecated

func (c APIClient) CreatePipeline(pipelineName, image string, cmd []string, stdin []string, parallelismSpec *pps.ParallelismSpec, input *pps.Input, outputBranch string, update bool) error

CreatePipeline creates a new pipeline, pipelines are the main computation object in PPS they create a flow of data from a set of input Repos to an output Repo (which has the same name as the pipeline). Whenever new data is committed to one of the input repos the pipelines will create jobs to bring the output Repo up to data.

image is the Docker image to run the jobs in.

cmd is the command passed to the Docker run invocation. NOTE as with Docker cmd is not run inside a shell that means that things like wildcard globbing (*), pipes (|) and file redirects (> and >>) will not work. To get that behavior you should have your command be a shell of your choice and pass a shell script to stdin.

stdin is a slice of lines that are sent to your command on stdin. Lines need not end in newline characters.

parallelism is how many copies of your container should run in parallel. You may pass 0 for parallelism in which case PPS will set the parallelism based on available resources.

input specifies a set of Repos that will be visible to the jobs during runtime. commits to these repos will cause the pipeline to create new jobs to process them. update indicates that you want to update an existing pipeline.

Deprecated: use CreateProjectPipeline instead.

func (APIClient) CreatePipelineService deprecated

func (c APIClient) CreatePipelineService(pipelineName, image string, cmd, stdin []string, parallelismSpec *pps.ParallelismSpec, input *pps.Input, update bool, internalPort, externalPort int32, annotations map[string]string) error

CreatePipelineService creates a new pipeline service.

Deprecated: use CreateProjectPipelineService instead.

func (APIClient) CreateProject

func (c APIClient) CreateProject(name string) error

CreateProject creates a new Project object in pfs with the given name.

func (APIClient) CreateProjectBranch

func (c APIClient) CreateProjectBranch(projectName, repoName, branchName, commitBranch, commitID string, provenance []*pfs.Branch) error

CreateProjectBranch creates a new branch

func (APIClient) CreateProjectBranchTrigger

func (c APIClient) CreateProjectBranchTrigger(projectName, repoName, branchName, commitBranch, commitID string, trigger *pfs.Trigger) error

CreateProjectBranchTrigger creates a branch with a trigger. Note: triggers and provenance are mutually exclusive. See the docs on triggers to learn more about why this is.

func (APIClient) CreateProjectPipeline

func (c APIClient) CreateProjectPipeline(projectName, pipelineName, image string, cmd []string, stdin []string, parallelismSpec *pps.ParallelismSpec, input *pps.Input, outputBranch string, update bool) error

CreatePipeline creates a new pipeline, pipelines are the main computation object in PPS they create a flow of data from a set of input Repos to an output Repo (which has the same name as the pipeline). Whenever new data is committed to one of the input repos the pipelines will create jobs to bring the output Repo up to data.

image is the Docker image to run the jobs in.

cmd is the command passed to the Docker run invocation. NOTE as with Docker cmd is not run inside a shell that means that things like wildcard globbing (*), pipes (|) and file redirects (> and >>) will not work. To get that behavior you should have your command be a shell of your choice and pass a shell script to stdin.

stdin is a slice of lines that are sent to your command on stdin. Lines need not end in newline characters.

parallelism is how many copies of your container should run in parallel. You may pass 0 for parallelism in which case PPS will set the parallelism based on available resources.

input specifies a set of Repos that will be visible to the jobs during runtime. commits to these repos will cause the pipeline to create new jobs to process them. update indicates that you want to update an existing pipeline.

func (APIClient) CreateProjectPipelineService

func (c APIClient) CreateProjectPipelineService(projectName, pipelineName, image string, cmd, stdin []string, parallelismSpec *pps.ParallelismSpec, input *pps.Input, update bool, internalPort, externalPort int32, annotations map[string]string) error

CreateProjectPipelineService creates a new pipeline service.

func (APIClient) CreateProjectRepo

func (c APIClient) CreateProjectRepo(projectName, repoName string) error

CreateProjectRepo creates a new Repo object in pfs with the given name. Repos are the top level data object in pfs and should be used to store data of a similar type. For example rather than having a single Repo for an entire project you might have separate Repos for logs, metrics, database dumps etc.

func (APIClient) CreateRepo deprecated

func (c APIClient) CreateRepo(repoName string) error

CreateRepo creates a new Repo object in pfs with the given name. Repos are the top level data object in pfs and should be used to store data of a similar type. For example rather than having a single Repo for an entire project you might have separate Repos for logs, metrics, database dumps etc.

Deprecated: use CreateProjectRepo instead.

func (APIClient) CreateSecret

func (c APIClient) CreateSecret(file []byte) error

CreateSecret creates a secret on the cluster.

func (*APIClient) Ctx

func (c *APIClient) Ctx() context.Context

Ctx is a convenience function that returns adds Pachyderm authn metadata to context.Background().

func (APIClient) DeleteAll

func (c APIClient) DeleteAll() error

DeleteAll deletes everything in the cluster. Use with caution, there is no undo. TODO: rewrite this to use transactions

func (APIClient) DeleteAllEnterprise

func (c APIClient) DeleteAllEnterprise() error

DeleteAllEnterprise deletes everything in the enterprise server. Use with caution, there is no undo. TODO: rewrite this to use transactions

func (APIClient) DeleteBranch deprecated

func (c APIClient) DeleteBranch(repoName string, branchName string, force bool) error

DeleteBranch deletes a branch, but leaves the commits themselves intact. In other words, those commits can still be accessed via commit IDs and other branches they happen to be on.

Deprecated: use DeleteProjectBranch instead.

func (APIClient) DeleteFile

func (c APIClient) DeleteFile(commit *pfs.Commit, path string, opts ...DeleteFileOption) error

DeleteFile deletes a file from PFS.

func (APIClient) DeleteJob deprecated

func (c APIClient) DeleteJob(pipelineName, jobID string) error

DeleteJob deletes a job.

Deprecated: use DeleteProjectJob instead.

func (APIClient) DeletePipeline deprecated

func (c APIClient) DeletePipeline(pipelineName string, force bool) error

DeletePipeline deletes a pipeline along with its output Repo.

Deprecated: use DeleteProjectPipeline instead.

func (APIClient) DeleteProject

func (c APIClient) DeleteProject(projectName string, force bool) error

DeleteProject deletes a project.

If "force" is set to true, the project will be removed regardless of errors. This argument should be used with care.

func (APIClient) DeleteProjectBranch

func (c APIClient) DeleteProjectBranch(projectName, repoName, branchName string, force bool) error

DeleteProjectBranch deletes a branch, but leaves the commits themselves intact. In other words, those commits can still be accessed via commit IDs and other branches they happen to be on.

func (APIClient) DeleteProjectJob

func (c APIClient) DeleteProjectJob(projectName, pipelineName, jobID string) error

DeleteProjectJob deletes a job.

func (APIClient) DeleteProjectPipeline

func (c APIClient) DeleteProjectPipeline(projectName, pipelineName string, force bool) error

DeleteProjectPipeline deletes a pipeline along with its output Repo.

func (APIClient) DeleteProjectRepo

func (c APIClient) DeleteProjectRepo(projectName, repoName string, force bool) error

DeleteProjectRepo deletes a repo and reclaims the storage space it was using. Note that as of 1.0 we do not reclaim the blocks that the Repo was referencing, this is because they may also be referenced by other Repos and deleting them would make those Repos inaccessible. This will be resolved in later versions.

If "force" is set to true, the repo will be removed regardless of errors. This argument should be used with care.

func (APIClient) DeleteRepo deprecated

func (c APIClient) DeleteRepo(repoName string, force bool) error

DeleteRepo deletes a repo and reclaims the storage space it was using. Note that as of 1.0 we do not reclaim the blocks that the Repo was referencing, this is because they may also be referenced by other Repos and deleting them would make those Repos inaccessible. This will be resolved in later versions.

If "force" is set to true, the repo will be removed regardless of errors. This argument should be used with care.

Deprecated: use DeleteProjectRepo instead.

func (APIClient) DeleteSecret

func (c APIClient) DeleteSecret(secret string) error

DeleteSecret deletes a secret from the cluster.

func (APIClient) DeleteTransaction

func (c APIClient) DeleteTransaction(txn *transaction.Transaction) error

DeleteTransaction is an RPC that aborts an existing transaction in the Pachyderm cluster and removes it from the cluster.

func (APIClient) DiffFile

func (c APIClient) DiffFile(newCommit *pfs.Commit, newPath string, oldCommit *pfs.Commit, oldPath string, shallow bool, cb func(*pfs.FileInfo, *pfs.FileInfo) error) (retErr error)

DiffFile returns the differences between 2 paths at 2 commits. It streams back one file at a time which is either from the new path, or the old path

func (APIClient) DiffFileAll

func (c APIClient) DiffFileAll(newCommit *pfs.Commit, newPath string, oldCommit *pfs.Commit, oldPath string, shallow bool) (_ []*pfs.FileInfo, _ []*pfs.FileInfo, retErr error)

DiffFileAll returns the differences between 2 paths at 2 commits.

func (APIClient) DropCommitSet

func (c APIClient) DropCommitSet(id string) error

DropCommitSet drop the commits of a CommitSet and all data included in those commits.

func (APIClient) Dump

func (c APIClient) Dump(filter *debug.Filter, limit int64, w io.Writer) (retErr error)

Dump collects a standard set of debugging information.

func (APIClient) ExecuteInTransaction

func (c APIClient) ExecuteInTransaction(f func(c *APIClient) error) (*transaction.TransactionInfo, error)

ExecuteInTransaction executes a callback within a transaction. The callback should use the passed in APIClient. If the callback returns a nil error, then the transaction will be finished. If the callback returns a non-nil error, then the transaction will be deleted.

func (APIClient) FindCommits

func (c APIClient) FindCommits(req *pfs.FindCommitsRequest) (*FindCommitsResponse, error)

FindCommits searches for commits that reference a supplied file being modified in a branch.

func (APIClient) FinishCommit deprecated

func (c APIClient) FinishCommit(repoName string, branchName string, commitID string) (retErr error)

FinishCommit ends the process of committing data to a Repo and persists the Commit. Once a Commit is finished the data becomes immutable and future attempts to write to it with PutFile will error.

Deprecated: use FinishProjectCommit instead.

func (APIClient) FinishProjectCommit

func (c APIClient) FinishProjectCommit(projectName, repoName, branchName, commitID string) (retErr error)

FinishProjectCommit ends the process of committing data to a Repo and persists the Commit. Once a Commit is finished the data becomes immutable and future attempts to write to it with PutFile will error.

func (APIClient) FinishTransaction

func (c APIClient) FinishTransaction(txn *transaction.Transaction) (*transaction.TransactionInfo, error)

FinishTransaction is an RPC that closes an existing transaction in the Pachyderm cluster and commits its changes to the persisted cluster metadata transactionally.

func (APIClient) Fsck

func (c APIClient) Fsck(fix bool, cb func(*pfs.FsckResponse) error, opts ...FsckOption) error

Fsck performs checks on pfs. Errors that are encountered will be passed onError. These aren't errors in the traditional sense, in that they don't prevent the completion of fsck. Errors that do prevent completion will be returned from the function.

func (APIClient) FsckFastExit

func (c APIClient) FsckFastExit() error

FsckFastExit performs checks on pfs, similar to Fsck, except that it returns the first fsck error it encounters and exits.

func (*APIClient) GetAddress

func (c *APIClient) GetAddress() *grpcutil.PachdAddress

GetAddress returns the pachd host:port with which 'c' is communicating. If 'c' was created using NewInCluster or NewOnUserMachine then this is how the address may be retrieved from the environment.

func (APIClient) GetClusterRoleBinding

func (c APIClient) GetClusterRoleBinding() (*auth.RoleBinding, error)

func (APIClient) GetFile

func (c APIClient) GetFile(commit *pfs.Commit, path string, w io.Writer, opts ...GetFileOption) (retErr error)

GetFile returns the contents of a file at a specific Commit. offset specifies a number of bytes that should be skipped in the beginning of the file. size limits the total amount of data returned, note you will get fewer bytes than size if you pass a value larger than the size of the file. If size is set to 0 then all of the data will be returned.

func (APIClient) GetFileReadSeeker

func (c APIClient) GetFileReadSeeker(commit *pfs.Commit, path string) (io.ReadSeeker, error)

GetFileReadSeeker returns a reader for the contents of a file at a specific Commit that permits Seeking to different points in the file.

func (APIClient) GetFileReader

func (c APIClient) GetFileReader(commit *pfs.Commit, path string) (io.Reader, error)

GetFileReader gets a reader for the specified path TODO: This should probably be an io.ReadCloser so we can close the rpc if the full file isn't read.

func (APIClient) GetFileSet deprecated

func (c APIClient) GetFileSet(repo, branch, commit string) (_ string, retErr error)

GetFileSet gets a file set for a commit.

Deprecated: use GetProjectFileSet instead.

func (APIClient) GetFileTAR

func (c APIClient) GetFileTAR(commit *pfs.Commit, path string) (io.ReadCloser, error)

GetFileTAR gets a tar file from PFS.

func (APIClient) GetFileURL

func (c APIClient) GetFileURL(commit *pfs.Commit, path, URL string) (retErr error)

GetFileURL gets the file at the specified URL

func (APIClient) GetLogs deprecated

func (c APIClient) GetLogs(pipelineName, jobID string, data []string, datumID string, master, follow bool, since time.Duration) *LogsIter

GetLogs gets logs from a job (logs includes stdout and stderr). 'pipelineName', 'jobID', 'data', and 'datumID', are all filters. To forego any filter, simply pass an empty value, though one of 'pipelineName' and 'jobID' must be set. Responses are written to 'messages'.

Deprecated: use GetProjectLogs instead.

func (APIClient) GetLogsLoki

func (c APIClient) GetLogsLoki(
	pipelineName string,
	jobID string,
	data []string,
	datumID string,
	master bool,
	follow bool,
	since time.Duration,
) *LogsIter

GetLogsLoki gets logs from a job (logs includes stdout and stderr). 'pipelineName', 'jobID', 'data', and 'datumID', are all filters. To forego any filter, simply pass an empty value, though one of 'pipelineName' and 'jobID' must be set. Responses are written to 'messages'.

func (APIClient) GetProjectFileSet

func (c APIClient) GetProjectFileSet(project, repo, branch, commit string) (_ string, retErr error)

GetProjectFileSet gets a file set for a commit in a project.

func (APIClient) GetProjectLogs

func (c APIClient) GetProjectLogs(projectName, pipelineName, jobID string, data []string, datumID string, master, follow bool, since time.Duration) *LogsIter

GetProjectLogs gets logs from a job (logs includes stdout and stderr). 'pipelineName', 'jobID', 'data', and 'datumID', are all filters. To forego any filter, simply pass an empty value, though one of 'pipelineName' and 'jobID' must be set. Responses are written to 'messages'.

func (APIClient) GetProjectLogsLoki

func (c APIClient) GetProjectLogsLoki(projectName, pipelineName, jobID string, data []string, datumID string, master, follow bool, since time.Duration) *LogsIter

GetProjectLogsLoki gets logs from a job (logs includes stdout and stderr). 'pipelineName', 'jobID', 'data', and 'datumID', are all filters. To forego any filter, simply pass an empty value, though one of 'pipelineName' and 'jobID' must be set. Responses are written to 'messages'.

func (APIClient) GetProjectRepoRoleBinding

func (c APIClient) GetProjectRepoRoleBinding(projectName, repoName string) (*auth.RoleBinding, error)

Return the roles bound to a repo within a project.

func (APIClient) GetProjectRoleBinding

func (c APIClient) GetProjectRoleBinding(project string) (*auth.RoleBinding, error)

func (APIClient) GetRepoRoleBinding deprecated

func (c APIClient) GetRepoRoleBinding(repoName string) (*auth.RoleBinding, error)

Deprecated: use GetProjectRepoRoleBinding instead.

func (APIClient) GetTransaction

func (c APIClient) GetTransaction() (*transaction.Transaction, error)

GetTransaction is a helper function to get the active transaction from the client's context metadata.

func (APIClient) GlobFile

func (c APIClient) GlobFile(commit *pfs.Commit, pattern string, cb func(fi *pfs.FileInfo) error) (retErr error)

GlobFile returns files that match a given glob pattern in a given commit, calling cb with each FileInfo. The pattern is documented here: https://golang.org/pkg/path/filepath/#Match

func (APIClient) GlobFileAll

func (c APIClient) GlobFileAll(commit *pfs.Commit, pattern string) (_ []*pfs.FileInfo, retErr error)

GlobFileAll returns files that match a given glob pattern in a given commit. The pattern is documented here: https://golang.org/pkg/path/filepath/#Match

func (APIClient) Health

func (c APIClient) Health() error

Health health checks pachd, it returns an error if pachd isn't healthy.

func (APIClient) InspectBranch deprecated

func (c APIClient) InspectBranch(repoName string, branchName string) (*pfs.BranchInfo, error)

InspectBranch returns information on a specific PFS branch.

Deprecated: use InspectProjectBranch instead.

func (APIClient) InspectCluster

func (c APIClient) InspectCluster() (*admin.ClusterInfo, error)

InspectCluster retrieves cluster state

func (APIClient) InspectClusterWithVersion

func (c APIClient) InspectClusterWithVersion(v *versionpb.Version) (*admin.ClusterInfo, error)

InspectCluster retrieves cluster state, and sends the server its version for the server to validate.

func (APIClient) InspectCommit deprecated

func (c APIClient) InspectCommit(repoName, branchName, commitID string) (_ *pfs.CommitInfo, retErr error)

InspectCommit returns info about a specific Commit.

Deprecated: use InspectProjectCommit instead.

func (APIClient) InspectCommitSet

func (c APIClient) InspectCommitSet(id string) (_ []*pfs.CommitInfo, retErr error)

InspectCommitSet returns info about a specific CommitSet.

func (APIClient) InspectDatum deprecated

func (c APIClient) InspectDatum(pipelineName string, jobID string, datumID string) (*pps.DatumInfo, error)

InspectDatum returns info about a single datum.

Deprecated: use InspectProjectDatum instead.

func (APIClient) InspectFile

func (c APIClient) InspectFile(commit *pfs.Commit, path string) (_ *pfs.FileInfo, retErr error)

InspectFile returns metadata about the specified file

func (APIClient) InspectJob deprecated

func (c APIClient) InspectJob(pipelineName string, jobID string, details bool) (_ *pps.JobInfo, retErr error)

InspectJob returns info about a specific job.

'details' indicates that the JobInfo.Details field should be filled out.

Deprecated: use InspectProjectJob instead.

func (APIClient) InspectJobSet

func (c APIClient) InspectJobSet(id string, details bool) (_ []*pps.JobInfo, retErr error)

func (APIClient) InspectPipeline deprecated

func (c APIClient) InspectPipeline(pipelineName string, details bool) (*pps.PipelineInfo, error)

InspectPipeline returns info about a specific pipeline. The name may include ancestry syntax or be a bare name.

Deprecated: use InspecProjectPipeline instead.

func (APIClient) InspectProject

func (c APIClient) InspectProject(name string) (*pfs.ProjectInfo, error)

InspectProject returns info about a specific Project.

func (APIClient) InspectProjectBranch

func (c APIClient) InspectProjectBranch(projectName, repoName string, branchName string) (*pfs.BranchInfo, error)

InspectProjectBranch returns information on a specific PFS branch.

func (APIClient) InspectProjectCommit

func (c APIClient) InspectProjectCommit(projectName, repoName, branchName, commitID string) (_ *pfs.CommitInfo, retErr error)

InspectProjectCommit returns info about a specific Commit.

func (APIClient) InspectProjectDatum

func (c APIClient) InspectProjectDatum(projectName, pipelineName, jobID, datumID string) (*pps.DatumInfo, error)

InspectProjectDatum returns info about a single datum.

func (APIClient) InspectProjectJob

func (c APIClient) InspectProjectJob(projectName, pipelineName, jobID string, details bool) (_ *pps.JobInfo, retErr error)

InspectProjectJob returns info about a specific job.

'details' indicates that the JobInfo.Details field should be filled out.

func (APIClient) InspectProjectPipeline

func (c APIClient) InspectProjectPipeline(projectName, pipelineName string, details bool) (*pps.PipelineInfo, error)

InspectProjectPipeline returns info about a specific pipeline. The name may include ancestry syntax or be a bare name.

func (APIClient) InspectProjectRepo

func (c APIClient) InspectProjectRepo(projectName, repoName string) (_ *pfs.RepoInfo, retErr error)

InspectProjectRepo returns info about a specific Repo.

func (APIClient) InspectRepo deprecated

func (c APIClient) InspectRepo(repoName string) (_ *pfs.RepoInfo, retErr error)

InspectRepo returns info about a specific Repo.

Deprecated: use InspectProjectRepo instead.

func (APIClient) InspectSecret

func (c APIClient) InspectSecret(secret string) (*pps.SecretInfo, error)

InspectSecret returns info about a specific secret.

func (APIClient) InspectTransaction

func (c APIClient) InspectTransaction(txn *transaction.Transaction) (*transaction.TransactionInfo, error)

InspectTransaction is an RPC that fetches the detailed information for an existing transaction in the Pachyderm cluster.

func (APIClient) IsAuthActive

func (c APIClient) IsAuthActive() (bool, error)

IsAuthActive returns whether auth is activated on the cluster

func (APIClient) ListBranch deprecated

func (c APIClient) ListBranch(repoName string) ([]*pfs.BranchInfo, error)

ListBranch lists the active branches on a Repo.

Deprecated: use ListProjectBranch instead.

func (APIClient) ListCommit

func (c APIClient) ListCommit(repo *pfs.Repo, to, from *pfs.Commit, number int64) ([]*pfs.CommitInfo, error)

ListCommit lists commits. If only `repo` is given, all commits in the repo are returned. If `to` is given, only the ancestors of `to`, including `to` itself, are considered. If `from` is given, only the descendents of `from`, including `from` itself, are considered. If `to` and `from` are the same commit, no commits will be returned. `number` determines how many commits are returned. If `number` is 0, all commits that match the aforementioned criteria are returned.

func (APIClient) ListCommitByRepo

func (c APIClient) ListCommitByRepo(repo *pfs.Repo) ([]*pfs.CommitInfo, error)

ListCommitByRepo lists all commits in a repo.

func (APIClient) ListCommitF

func (c APIClient) ListCommitF(repo *pfs.Repo, to, from *pfs.Commit, number int64, reverse bool, f func(*pfs.CommitInfo) error) error

ListCommitF lists commits, calling f with each commit. If only `repo` is given, all commits in the repo are returned. If `to` is given, only the ancestors of `to`, including `to` itself, are considered. If `from` is given, only the descendents of `from`, including `from` itself, are considered. If `to` and `from` are the same commit, no commits will be returned. `number` determines how many commits are returned. If `number` is 0, `reverse` lists the commits from oldest to newest, rather than newest to oldest all commits that match the aforementioned criteria are passed to f.

func (APIClient) ListDatum deprecated

func (c APIClient) ListDatum(pipelineName, jobID string, cb func(*pps.DatumInfo) error) (retErr error)

ListDatum returns info about datums in a job.

Deprecated: use ListProjectDatum instead.

func (APIClient) ListDatumAll deprecated

func (c APIClient) ListDatumAll(pipelineName, jobID string) (_ []*pps.DatumInfo, retErr error)

ListDatumAll returns info about datums in a job.

Deprecated: use ListProjectDatumAll instead.

func (APIClient) ListDatumInput

func (c APIClient) ListDatumInput(input *pps.Input, cb func(*pps.DatumInfo) error) (retErr error)

ListDatumInput returns info about datums for a pipeline with input. The pipeline doesn't need to exist.

func (APIClient) ListDatumInputAll

func (c APIClient) ListDatumInputAll(input *pps.Input) (_ []*pps.DatumInfo, retErr error)

ListDatumInputAll returns info about datums for a pipeline with input. The pipeline doesn't need to exist.

func (APIClient) ListFile

func (c APIClient) ListFile(commit *pfs.Commit, path string, cb func(fi *pfs.FileInfo) error) (retErr error)

ListFile returns info about all files in a Commit under path, calling cb with each FileInfo.

func (APIClient) ListFileAll

func (c APIClient) ListFileAll(commit *pfs.Commit, path string) (_ []*pfs.FileInfo, retErr error)

ListFileAll returns info about all files in a Commit under path.

func (APIClient) ListJob deprecated

func (c APIClient) ListJob(pipelineName string, inputCommit []*pfs.Commit, history int64, details bool) ([]*pps.JobInfo, error)

ListJob returns info about all jobs.

If pipelineName is non empty then only jobs that were started by the named pipeline will be returned.

If inputCommit is non-nil then only jobs which took the specific commits as inputs will be returned.

The order of the inputCommits doesn't matter.

If outputCommit is non-nil then only the job which created that commit as output will be returned.

'history' controls whether jobs from historical versions of pipelines are returned, it has the following semantics:

  • 0: Return jobs from the current version of the pipeline or pipelines.
  • 1: Return the above and jobs from the next most recent version
  • 2: etc.
  • -1: Return jobs from all historical versions.

'details' controls whether the JobInfo passed to 'f' includes details from the pipeline spec (e.g. the transform). Leaving this 'false' can improve performance.

Deprecated: use ListProjectJob instead.

func (APIClient) ListJobF deprecated

func (c APIClient) ListJobF(pipelineName string, inputCommit []*pfs.Commit,
	history int64, details bool,
	f func(*pps.JobInfo) error) error

ListJobF is a previous version of ListJobFilterF, returning info about all jobs and calling f on each JobInfo

Deprecated: Use ListProjectJobF instead.

func (APIClient) ListJobFilterF

func (c APIClient) ListJobFilterF(pipelineName string, inputCommit []*pfs.Commit,
	history int64, details bool, jqFilter string,
	f func(*pps.JobInfo) error) error

ListJobFilterF returns info about all jobs, calling f with each JobInfo.

If f returns an error iteration of jobs will stop and ListJobF will return that error, unless the error is errutil.ErrBreak in which case it will return nil.

If pipelineName is non empty then only jobs that were started by the named pipeline will be returned.

If inputCommit is non-nil then only jobs which took the specific commits as inputs will be returned.

The order of the inputCommits doesn't matter.

If outputCommit is non-nil then only the job which created that commit as output will be returned.

'history' controls whether jobs from historical versions of pipelines are returned, it has the following semantics:

  • 0: Return jobs from the current version of the pipeline or pipelines.
  • 1: Return the above and jobs from the next most recent version
  • 2: etc.
  • -1: Return jobs from all historical versions.

'details' controls whether the JobInfo passed to 'f' includes details from the pipeline spec--setting this to 'false' can improve performance.

func (APIClient) ListPipeline

func (c APIClient) ListPipeline(details bool) ([]*pps.PipelineInfo, error)

ListPipeline returns info about all pipelines.

func (APIClient) ListPipelineHistory deprecated

func (c APIClient) ListPipelineHistory(pipelineName string, history int64, details bool) ([]*pps.PipelineInfo, error)
  • 0: Return the current version of the pipeline or pipelines.
  • 1: Return the above and the next most recent version
  • 2: etc.
  • -1: Return all historical versions.

Deprecated: use ListProjectPipelineHistory instead.

func (APIClient) ListProject

func (c APIClient) ListProject() (_ []*pfs.ProjectInfo, retErr error)

ListProject lists projects.

func (APIClient) ListProjectBranch

func (c APIClient) ListProjectBranch(projectName, repoName string) ([]*pfs.BranchInfo, error)

ListProjectBranch lists the active branches on a Repo.

func (APIClient) ListProjectDatum

func (c APIClient) ListProjectDatum(projectName, pipelineName, jobID string, cb func(*pps.DatumInfo) error) (retErr error)

ListProjectDatum returns info about datums in a job.

func (APIClient) ListProjectDatumAll

func (c APIClient) ListProjectDatumAll(projectName, pipelineName, jobID string) (_ []*pps.DatumInfo, retErr error)

ListProjectDatumAll returns info about datums in a job.

func (APIClient) ListProjectJob

func (c APIClient) ListProjectJob(projectName, pipelineName string, inputCommit []*pfs.Commit, history int64, details bool) ([]*pps.JobInfo, error)

ListProjectJob returns info about all jobs.

If projectName & pipelineName are non empty then only jobs that were started by the named pipeline will be returned.

If inputCommit is non-nil then only jobs which took the specific commits as inputs will be returned.

The order of the inputCommits doesn't matter.

If outputCommit is non-nil then only the job which created that commit as output will be returned.

'history' controls whether jobs from historical versions of pipelines are returned, it has the following semantics:

  • 0: Return jobs from the current version of the pipeline or pipelines.
  • 1: Return the above and jobs from the next most recent version
  • 2: etc.
  • -1: Return jobs from all historical versions.

'details' controls whether the JobInfo passed to 'f' includes details from the pipeline spec (e.g. the transform). Leaving this 'false' can improve performance.

func (APIClient) ListProjectJobF

func (c APIClient) ListProjectJobF(projectName, pipelineName string, inputCommit []*pfs.Commit,
	history int64, details bool,
	f func(*pps.JobInfo) error) error

ListProjectJobF is a previous version of ListJobFilterF, returning info about all jobs and calling f on each JobInfo

func (APIClient) ListProjectJobFilterF

func (c APIClient) ListProjectJobFilterF(projectName, pipelineName string, inputCommit []*pfs.Commit,
	history int64, details bool, jqFilter string,
	f func(*pps.JobInfo) error) error

ListProjectJobFilterF returns info about all jobs, calling f with each JobInfo.

If f returns an error iteration of jobs will stop and ListJobF will return that error, unless the error is errutil.ErrBreak in which case it will return nil.

If projectName & pipelineName are both non-empty then only jobs that were started by the named pipeline will be returned.

If inputCommit is non-nil then only jobs which took the specific commits as inputs will be returned.

The order of the inputCommits doesn't matter.

If outputCommit is non-nil then only the job which created that commit as output will be returned.

'history' controls whether jobs from historical versions of pipelines are returned, it has the following semantics:

  • 0: Return jobs from the current version of the pipeline or pipelines.
  • 1: Return the above and jobs from the next most recent version
  • 2: etc.
  • -1: Return jobs from all historical versions.

'details' controls whether the JobInfo passed to 'f' includes details from the pipeline spec--setting this to 'false' can improve performance.

func (APIClient) ListProjectPipelineHistory

func (c APIClient) ListProjectPipelineHistory(projectName, pipelineName string, history int64, details bool) ([]*pps.PipelineInfo, error)

- 0: Return the current version of the pipeline or pipelines. - 1: Return the above and the next most recent version - 2: etc. - -1: Return all historical versions.

func (APIClient) ListProjectRepo

func (c APIClient) ListProjectRepo(r *pfs.ListRepoRequest) ([]*pfs.RepoInfo, error)

ListProjectRepo returns a list of RepoInfos given a ListRepoRequest, which can include information about which projects to filter with.

func (APIClient) ListRepo

func (c APIClient) ListRepo() ([]*pfs.RepoInfo, error)

ListRepo returns info about user Repos

func (APIClient) ListRepoByType

func (c APIClient) ListRepoByType(repoType string) (_ []*pfs.RepoInfo, retErr error)

ListRepoByType returns info about Repos of the given type.

The if repoType is empty, all Repos will be included

func (APIClient) ListSecret

func (c APIClient) ListSecret() ([]*pps.SecretInfo, error)

ListSecret returns info about all Pachyderm secrets.

func (APIClient) ListTask

func (c APIClient) ListTask(service string, namespace, group string, cb func(*task.TaskInfo) error) (retErr error)

ListTask lists tasks in the given namespace and group

func (APIClient) ListTransaction

func (c APIClient) ListTransaction() ([]*transaction.TransactionInfo, error)

ListTransaction is an RPC that fetches a list of all open transactions in the Pachyderm cluster.

func (APIClient) ModifyClusterRoleBinding

func (c APIClient) ModifyClusterRoleBinding(principal string, roles []string) error

func (APIClient) ModifyProjectRepoRoleBinding

func (c APIClient) ModifyProjectRepoRoleBinding(projectName, repoName, principal string, roles []string) error

Update the roles bound to a repo within a project.

func (APIClient) ModifyProjectRoleBinding

func (c APIClient) ModifyProjectRoleBinding(projectName, principal string, roles []string) error

ModifyProjectRoleBinding binds a user's roles to a project.

func (APIClient) ModifyRepoRoleBinding deprecated

func (c APIClient) ModifyRepoRoleBinding(repoName, principal string, roles []string) error

Deprecated: use ModifyProjectRepoRoleBinding instead.

func (APIClient) NewCreateFileSetClient

func (c APIClient) NewCreateFileSetClient() (_ *CreateFileSetClient, retErr error)

NewCreateFileSetClient returns a CreateFileSetClient instance backed by this client

func (APIClient) NewModifyFileClient

func (c APIClient) NewModifyFileClient(commit *pfs.Commit) (_ *ModifyFileClient, retErr error)

NewModifyFileClient creates a new ModifyFileClient.

func (APIClient) Profile

func (c APIClient) Profile(profile *debug.Profile, filter *debug.Filter, w io.Writer) (retErr error)

Profile collects a set of pprof profiles.

func (APIClient) PutFile

func (c APIClient) PutFile(commit *pfs.Commit, path string, r io.Reader, opts ...PutFileOption) error

PutFile puts a file into PFS from a reader.

func (APIClient) PutFileTAR

func (c APIClient) PutFileTAR(commit *pfs.Commit, r io.Reader, opts ...PutFileOption) error

PutFileTAR puts a set of files into PFS from a tar stream.

func (APIClient) PutFileURL

func (c APIClient) PutFileURL(commit *pfs.Commit, path, url string, recursive bool, opts ...PutFileOption) error

PutFileURL puts a file into PFS using the content found at a URL. The URL is sent to the server which performs the request. recursive allow for recursive scraping of some types of URLs for example on s3:// urls.

func (APIClient) RenewFileSet

func (c APIClient) RenewFileSet(ID string, ttl time.Duration) (retErr error)

RenewFileSet renews a fileset.

func (APIClient) RestartDatum deprecated

func (c APIClient) RestartDatum(pipelineName string, jobID string, datumFilter []string) error

RestartDatum restarts a datum that's being processed as part of a job.

datumFilter is a slice of strings which are matched against either the Path or Hash of the datum, the order of the strings in datumFilter is irrelevant.

Deprecated: use RestartProjectDatum instead.

func (APIClient) RestartProjectDatum

func (c APIClient) RestartProjectDatum(projectName, pipelineName, jobID string, datumFilter []string) error

RestartProjectDatum restarts a datum that's being processed as part of a job.

datumFilter is a slice of strings which are matched against either the Path or Hash of the datum, the order of the strings in datumFilter is irrelevant.

func (APIClient) RunBatchInTransaction

func (c APIClient) RunBatchInTransaction(cb func(builder *TransactionBuilder) error) (*transaction.TransactionInfo, error)

RunBatchInTransaction will execute a batch of API calls in a single round-trip transactionally. The callback is used to build the request, which is executed when the callback returns.

func (APIClient) RunCron deprecated

func (c APIClient) RunCron(pipelineName string) error

RunCron runs a pipeline. It can be passed a list of commit provenance. This will trigger a new job provenant on those commits, effectively running the pipeline on the data in those commits.

Deprecated: use RunProjectCron instead.

func (APIClient) RunPipeline deprecated

func (c APIClient) RunPipeline(pipelineName string, provenance []*pfs.Commit, jobID string) error

RunPipeline runs a pipeline. It can be passed a list of commit provenance. This will trigger a new job provenant on those commits, effectively running the pipeline on the data in those commits.

Deprecated: use RunProjectPipeline instead.

func (APIClient) RunProjectCron

func (c APIClient) RunProjectCron(projectName, pipelineName string) error

RunProjectCron runs a pipeline. It can be passed a list of commit provenance. This will trigger a new job provenant on those commits, effectively running the pipeline on the data in those commits.

func (APIClient) RunProjectPipeline

func (c APIClient) RunProjectPipeline(projectName, pipelineName string, provenance []*pfs.Commit, jobID string) error

RunProjectPipeline runs a pipeline. It can be passed a list of commit provenance. This will trigger a new job provenant on those commits, effectively running the pipeline on the data in those commits.

func (*APIClient) SetAuthToken

func (c *APIClient) SetAuthToken(token string)

SetAuthToken sets the authentication token that will be used for all API calls for this client.

func (APIClient) ShardFileSet

func (c APIClient) ShardFileSet(ID string) (_ []*pfs.PathRange, retErr error)

func (APIClient) SquashCommitSet

func (c APIClient) SquashCommitSet(id string) error

SquashCommitSet squashes the commits of a CommitSet into their children.

func (APIClient) StartCommit deprecated

func (c APIClient) StartCommit(repoName string, branchName string) (_ *pfs.Commit, retErr error)

StartCommit begins the process of committing data to a Repo. Once started you can write to the Commit with PutFile and when all the data has been written you must finish the Commit with FinishCommit. NOTE, data is not persisted until FinishCommit is called.

branch is a more convenient way to build linear chains of commits. When a commit is started with a non empty branch the value of branch becomes an alias for the created Commit. This enables a more intuitive access pattern. When the commit is started on a branch the previous head of the branch is used as the parent of the commit.

Deprecated: use StartProjectCommit instead.

func (APIClient) StartCommitParent deprecated

func (c APIClient) StartCommitParent(repoName, branchName, parentBranch, parentCommit string) (*pfs.Commit, error)

StartCommitParent begins the process of committing data to a Repo. Once started you can write to the Commit with PutFile and when all the data has been written you must finish the Commit with FinishCommit. NOTE, data is not persisted until FinishCommit is called. branch is a more convenient way to build linear chains of commits. When a commit is started with a non empty branch the value of branch becomes an alias for the created Commit. This enables a more intuitive access pattern. When the commit is started on a branch the previous head of the branch is used as the parent of the commit. parentCommit specifies the parent Commit, upon creation the new Commit will appear identical to the parent Commit, data can safely be added to the new commit without affecting the contents of the parent Commit. You may pass "" as parentCommit in which case the new Commit will have no parent and will initially appear empty.

Deprecated: use StartProjectCommitParent instead.

func (APIClient) StartPipeline deprecated

func (c APIClient) StartPipeline(pipelineName string) error

StartPipeline restarts a stopped pipeline.

Deprecated: use StartProjectPipeline instead.

func (APIClient) StartProjectCommit

func (c APIClient) StartProjectCommit(projectName, repoName string, branchName string) (_ *pfs.Commit, retErr error)

StartProjectCommit begins the process of committing data to a Repo. Once started you can write to the Commit with PutFile and when all the data has been written you must finish the Commit with FinishCommit. NOTE, data is not persisted until FinishCommit is called.

branch is a more convenient way to build linear chains of commits. When a commit is started with a non empty branch the value of branch becomes an alias for the created Commit. This enables a more intuitive access pattern. When the commit is started on a branch the previous head of the branch is used as the parent of the commit.

func (APIClient) StartProjectCommitParent

func (c APIClient) StartProjectCommitParent(projectName, repoName, branchName, parentBranch, parentCommit string) (*pfs.Commit, error)

StartProjectCommitParent begins the process of committing data to a Repo. Once started you can write to the Commit with PutFile and when all the data has been written you must finish the Commit with FinishCommit. NOTE, data is not persisted until FinishCommit is called.

branch is a more convenient way to build linear chains of commits. When a commit is started with a non empty branch the value of branch becomes an alias for the created Commit. This enables a more intuitive access pattern. When the commit is started on a branch the previous head of the branch is used as the parent of the commit.

parentCommit specifies the parent Commit, upon creation the new Commit will appear identical to the parent Commit, data can safely be added to the new commit without affecting the contents of the parent Commit. You may pass "" as parentCommit in which case the new Commit will have no parent and will initially appear empty.

func (APIClient) StartProjectPipeline

func (c APIClient) StartProjectPipeline(projectName, pipelineName string) error

StartProjectPipeline restarts a stopped pipeline.

func (APIClient) StartTransaction

func (c APIClient) StartTransaction() (*transaction.Transaction, error)

StartTransaction is an RPC that registers a new transaction with the Pachyderm cluster and returns the identifier of the new transaction.

func (APIClient) StopJob deprecated

func (c APIClient) StopJob(pipelineName string, jobID string) error

StopJob stops a job.

Deprecated: use StopProjectJob instead.

func (APIClient) StopPipeline deprecated

func (c APIClient) StopPipeline(pipelineName string) error

StopPipeline prevents a pipeline from processing things; it can be restarted with StartProjectPipeline.

Deprecated: use StopProjectPipeline instead.

func (APIClient) StopProjectJob

func (c APIClient) StopProjectJob(projectName, pipelineName, jobID string) error

StopProjectJob stops a job.

func (APIClient) StopProjectPipeline

func (c APIClient) StopProjectPipeline(projectName, pipelineName string) error

StopProjectPipeline prevents a pipeline from processing things; it can be restarted with StartProjectPipeline.

func (APIClient) SubscribeCommit

func (c APIClient) SubscribeCommit(repo *pfs.Repo, branchName string, from string, state pfs.CommitState, cb func(*pfs.CommitInfo) error) (retErr error)

SubscribeCommit is like ListCommit but it keeps listening for commits as they come in.

func (APIClient) SubscribeJob deprecated

func (c APIClient) SubscribeJob(pipelineName string, details bool, cb func(*pps.JobInfo) error) error

SubscribeJob calls the given callback with each open job in the given pipeline until cancelled.

Deprecated: use SubscribeProjectJob instead.

func (APIClient) SubscribeProjectJob

func (c APIClient) SubscribeProjectJob(projectName, pipelineName string, details bool, cb func(*pps.JobInfo) error) error

SubscribeProjectJob calls the given callback with each open job in the given pipeline until cancelled.

func (APIClient) UpdateProject

func (c APIClient) UpdateProject(projectName, description string) error

UpdateProject upserts a project with the given name.

func (APIClient) UpdateProjectRepo

func (c APIClient) UpdateProjectRepo(projectName, repoName string) error

UpdateProjectRepo upserts a repo with the given name.

func (APIClient) UpdateRepo deprecated

func (c APIClient) UpdateRepo(repoName string) error

UpdateRepo upserts a repo with the given name.

Deprecated: use UpdateProjectRepo instead.

func (APIClient) Version

func (c APIClient) Version() (string, error)

Version returns the version of pachd as a string.

func (APIClient) WaitCommit deprecated

func (c APIClient) WaitCommit(repoName, branchName, commitID string) (_ *pfs.CommitInfo, retErr error)

WaitCommit returns info about a specific Commit, but blocks until that commit has been finished.

Deprecated: use WaitProjectCommit instead.

func (APIClient) WaitCommitSet

func (c APIClient) WaitCommitSet(id string, cb func(*pfs.CommitInfo) error) (retErr error)

WaitCommitSet blocks until each of a CommitSet's commits are finished, passing them to the given callback as they finish. To wait for an individual commit, use WaitCommit instead.

func (APIClient) WaitCommitSetAll

func (c APIClient) WaitCommitSetAll(id string) (_ []*pfs.CommitInfo, retErr error)

WaitCommitSetAll blocks until all of a CommitSet's commits are finished. To wait for an individual commit, use WaitCommit instead.

func (APIClient) WaitJob

func (c APIClient) WaitJob(pipelineName string, jobID string, details bool) (_ *pps.JobInfo, retErr error)

WaitJob is a blocking version of InspectJob that will wait until the job has reached a terminal state.

Deprecate: use WaitProjectJob instead.

func (APIClient) WaitJobSet

func (c APIClient) WaitJobSet(id string, details bool, cb func(*pps.JobInfo) error) (retErr error)

func (APIClient) WaitJobSetAll

func (c APIClient) WaitJobSetAll(id string, details bool) (_ []*pps.JobInfo, retErr error)

func (APIClient) WaitProjectCommit

func (c APIClient) WaitProjectCommit(projectName, repoName, branchName, commitID string) (_ *pfs.CommitInfo, retErr error)

WaitProjectCommit returns info about a specific Commit, but blocks until that commit has been finished.

func (APIClient) WaitProjectJob

func (c APIClient) WaitProjectJob(projectName, pipelineName, jobID string, details bool) (_ *pps.JobInfo, retErr error)

WaitProjectJob is a blocking version of InspectJob that will wait until the job has reached a terminal state.

func (APIClient) WalkFile

func (c APIClient) WalkFile(commit *pfs.Commit, path string, cb func(*pfs.FileInfo) error) (retErr error)

WalkFile walks the files under path.

func (APIClient) WithCreateFileSetClient

func (c APIClient) WithCreateFileSetClient(cb func(ModifyFile) error) (resp *pfs.CreateFileSetResponse, retErr error)

WithCreateFileSetClient provides a scoped fileset client.

func (*APIClient) WithCtx

func (c *APIClient) WithCtx(ctx context.Context) *APIClient

WithCtx returns a new APIClient that uses ctx for requests it sends. Note that the new APIClient will still use the authentication token and metrics metadata of this client, so this is only useful for propagating other context-associated metadata.

func (APIClient) WithDefaultTransformImage

func (c APIClient) WithDefaultTransformImage(x string) *APIClient

WithDefaultTransformImage sets the image used when the empty string "" is passed as the image in calls to CreatePipeline*

func (APIClient) WithDefaultTransformUser

func (c APIClient) WithDefaultTransformUser(x string) *APIClient

WithDefaultTransformUser sets the user to run the transform container as. This overrides the user set by the image.

func (APIClient) WithModifyFileClient

func (c APIClient) WithModifyFileClient(commit *pfs.Commit, cb func(ModifyFile) error) (retErr error)

WithModifyFileClient creates a new ModifyFileClient that is scoped to the passed in callback. TODO: Context should be a parameter, not stored in the pach client.

func (APIClient) WithRenewer

func (c APIClient) WithRenewer(cb func(context.Context, *renew.StringSet) error) error

WithRenewer provides a scoped fileset renewer.

func (APIClient) WithTransaction

func (c APIClient) WithTransaction(txn *transaction.Transaction) *APIClient

WithTransaction (client-side) returns a new APIClient that will run supported write operations within the specified transaction.

func (APIClient) WithoutTransaction

func (c APIClient) WithoutTransaction() *APIClient

WithoutTransaction returns a new APIClient which will run all future operations outside of any active transaction Removing from both incoming and outgoing metadata is necessary because Ctx() merges them

type AdminAPIClient

type AdminAPIClient admin.APIClient

AdminAPIClient is an alias of admin.APIClient

type AuthAPIClient

type AuthAPIClient auth.APIClient

AuthAPIClient is an alias of auth.APIClient

type CopyFileOption

type CopyFileOption func(*pfs.CopyFile)

CopyFileOption configures a CopyFile call.

func WithAppendCopyFile

func WithAppendCopyFile() CopyFileOption

WithAppendCopyFile configures the CopyFile call to append to existing files.

func WithDatumCopyFile

func WithDatumCopyFile(datum string) CopyFileOption

WithDatumCopyFile configures the CopyFile call to apply to a particular datum.

type CreateFileSetClient

type CreateFileSetClient struct {
	// contains filtered or unexported fields
}

CreateFileSetClient is used to create a temporary fileset.

func (*CreateFileSetClient) Close

Close closes the CreateFileSetClient.

func (*CreateFileSetClient) CopyFile

func (mfc *CreateFileSetClient) CopyFile(dst string, src *pfs.File, opts ...CopyFileOption) error

func (*CreateFileSetClient) DeleteFile

func (mfc *CreateFileSetClient) DeleteFile(path string, opts ...DeleteFileOption) error

func (*CreateFileSetClient) PutFile

func (mfc *CreateFileSetClient) PutFile(path string, r io.Reader, opts ...PutFileOption) error

func (*CreateFileSetClient) PutFileTAR

func (mfc *CreateFileSetClient) PutFileTAR(r io.Reader, opts ...PutFileOption) error

func (*CreateFileSetClient) PutFileURL

func (mfc *CreateFileSetClient) PutFileURL(path, url string, recursive bool, opts ...PutFileOption) error

type DebugClient

type DebugClient debug.DebugClient

DebugClient is an alias of debug.DebugClient

type DeleteFileOption

type DeleteFileOption func(*deleteFileConfig)

DeleteFileOption configures a DeleteFile call.

func WithDatumDeleteFile

func WithDatumDeleteFile(datum string) DeleteFileOption

WithDatumDeleteFile configures the DeleteFile call to apply to a particular datum.

func WithRecursiveDeleteFile

func WithRecursiveDeleteFile() DeleteFileOption

WithRecursiveDeleteFile configures the DeleteFile call to recursively delete the files in a directory.

type FindCommitsResponse

type FindCommitsResponse struct {
	FoundCommits       []*pfs.Commit
	LastSearchedCommit *pfs.Commit
	CommitsSearched    uint32
}

FindCommitsResponse is a merged response of *pfs.FindCommitsResponse items that is presented to users.

type FsckOption

type FsckOption func(*pfs.FsckRequest)

func WithZombieCheckAll

func WithZombieCheckAll() FsckOption

func WithZombieCheckTarget

func WithZombieCheckTarget(c *pfs.Commit) FsckOption

type GetFileOption

type GetFileOption func(*pfs.GetFileRequest)

GetFileOption configures a GetFile call

func WithDatumGetFile

func WithDatumGetFile(datum string) GetFileOption

WithDatumGetFile sets the datum for the get file request

func WithOffset

func WithOffset(offset int64) GetFileOption

type IdentityAPIClient

type IdentityAPIClient identity.APIClient

IdentityAPIClient is an alias of identity.APIClient

type LogsIter

type LogsIter struct {
	// contains filtered or unexported fields
}

LogsIter iterates through log messages returned from pps.GetLogs. Logs can be fetched with 'Next()'. The log message received can be examined with 'Message()', and any errors can be examined with 'Err()'.

func (*LogsIter) Err

func (l *LogsIter) Err() error

Err retrieves any errors encountered in the course of calling 'Next()'.

func (*LogsIter) Message

func (l *LogsIter) Message() *pps.LogMessage

Message returns the most recently retrieve log message (as an annotated log line, in the form of a pps.LogMessage)

func (*LogsIter) Next

func (l *LogsIter) Next() bool

Next retrieves the next relevant log message from pachd

type ModifyFile

type ModifyFile interface {
	// PutFile puts a file into PFS from a reader.
	PutFile(path string, r io.Reader, opts ...PutFileOption) error
	// PutFileTAR puts a set of files into PFS from a tar stream.
	PutFileTAR(r io.Reader, opts ...PutFileOption) error
	// PutFileURL puts a file into PFS using the content found at a URL.
	// recursive allows for recursive scraping of some types of URLs.
	PutFileURL(path, url string, recursive bool, opts ...PutFileOption) error
	// DeleteFile deletes a file from PFS.
	DeleteFile(path string, opts ...DeleteFileOption) error
	// CopyFile copies a file from src to dst.
	CopyFile(dst string, src *pfs.File, opts ...CopyFileOption) error
}

ModifyFile is used for performing a stream of file modifications. The modifications are not persisted until the ModifyFileClient is closed. ModifyFileClient is not thread safe. Multiple ModifyFileClients should be used for concurrent modifications.

type ModifyFileClient

type ModifyFileClient struct {
	// contains filtered or unexported fields
}

func NewNoOpModifyFileClient

func NewNoOpModifyFileClient() *ModifyFileClient

NewNoOpModifyFileClient returns a ModifyFileClient that does nothing; it accepts any operation and does not error.

func (*ModifyFileClient) Close

func (mfc *ModifyFileClient) Close() error

Close closes the ModifyFileClient.

func (*ModifyFileClient) CopyFile

func (mfc *ModifyFileClient) CopyFile(dst string, src *pfs.File, opts ...CopyFileOption) error

func (*ModifyFileClient) DeleteFile

func (mfc *ModifyFileClient) DeleteFile(path string, opts ...DeleteFileOption) error

func (*ModifyFileClient) PutFile

func (mfc *ModifyFileClient) PutFile(path string, r io.Reader, opts ...PutFileOption) error

func (*ModifyFileClient) PutFileTAR

func (mfc *ModifyFileClient) PutFileTAR(r io.Reader, opts ...PutFileOption) error

func (*ModifyFileClient) PutFileURL

func (mfc *ModifyFileClient) PutFileURL(path, url string, recursive bool, opts ...PutFileOption) error

type Option

type Option func(*clientSettings) error

Option is a client creation option that may be passed to NewOnUserMachine(), or NewInCluster()

func WithAdditionalPachdCert

func WithAdditionalPachdCert() Option

WithAdditionalPachdCert instructs the New* functions to additionally trust the signed cert mounted in Pachd's cert volume. This is used by Pachd when connecting to itself (if no cert is present, the clients cert pool will not be modified, so that if no other options have been passed, pachd will connect to itself over an insecure connection)

func WithAdditionalRootCAs

func WithAdditionalRootCAs(pemBytes []byte) Option

WithAdditionalRootCAs instructs the New* functions to additionally trust the given base64-encoded, signed x509 certificates as root certificates. Introduced to pass certs in the Pachyderm config

func WithAdditionalStreamClientInterceptors

func WithAdditionalStreamClientInterceptors(interceptors ...grpc.StreamClientInterceptor) Option

WithAdditionalStreamClientInterceptors instructs the New* functions to add the provided StreamClientInterceptors to the gRPC dial options when opening a client connection. Internally, all of the provided options are coalesced into one chain, so it is safe to provide this option more than once.

This client creates both Unary and Stream client connections, so you will probably want to supply a corresponding WithAdditionalUnaryClientInterceptors option.

func WithAdditionalUnaryClientInterceptors

func WithAdditionalUnaryClientInterceptors(interceptors ...grpc.UnaryClientInterceptor) Option

WithAdditionalUnaryClientInterceptors instructs the New* functions to add the provided UnaryClientInterceptors to the gRPC dial options when opening a client connection. Internally, all of the provided options are coalesced into one chain, so it is safe to provide this option more than once.

This client creates both Unary and Stream client connections, so you will probably want to supply a corresponding WithAdditionalStreamClientInterceptors call.

func WithCertPool

func WithCertPool(pool *x509.CertPool) Option

WithCertPool instructs the New* functions to create a client that uses the provided cert pool to validate the server's identity when connecting with TLS.

func WithDialTimeout

func WithDialTimeout(t time.Duration) Option

WithDialTimeout instructs the New* functions to use 't' as the deadline to connect to pachd

func WithGZIPCompression

func WithGZIPCompression() Option

WithGZIPCompression enabled GZIP compression for data on the wire

func WithMaxConcurrentStreams

func WithMaxConcurrentStreams(streams int) Option

WithMaxConcurrentStreams instructs the New* functions to create client that can have at most 'streams' concurrent streams open with pachd at a time

func WithRootCAs

func WithRootCAs(path string) Option

WithRootCAs instructs the New* functions to create client that uses the given signed x509 certificates as the trusted root certificates (instead of the system certs). Introduced to pass certs provided via command-line flags

type PfsAPIClient

type PfsAPIClient pfs.APIClient

PfsAPIClient is an alias for pfs.APIClient.

type PortForwarder

type PortForwarder struct {
	// contains filtered or unexported fields
}

PortForwarder handles proxying local traffic to a kubernetes pod

func NewPortForwarder

func NewPortForwarder(context *config.Context, namespace string) (*PortForwarder, error)

NewPortForwarder creates a new port forwarder

func (*PortForwarder) Close

func (f *PortForwarder) Close()

Close shuts down port forwarding.

func (*PortForwarder) Run

func (f *PortForwarder) Run(appName string, localPort, remotePort uint16, selectors ...string) (uint16, error)

Run starts the port forwarder. Returns after initialization is begun with the locally bound port and any initialization errors.

func (*PortForwarder) RunForConsole

func (f *PortForwarder) RunForConsole(localPort, remotePort uint16) (uint16, error)

RunForConsole creates a port forwarder for console

func (*PortForwarder) RunForEnterpriseServer

func (f *PortForwarder) RunForEnterpriseServer(localPort, remotePort uint16) (uint16, error)

RunForEnterpriseServer creates a port forwarder for the enterprise server

func (*PortForwarder) RunForPachd

func (f *PortForwarder) RunForPachd(localPort, remotePort uint16) (uint16, error)

RunForDaemon creates a port forwarder for the pachd daemon.

type PpsAPIClient

type PpsAPIClient pps.APIClient

PpsAPIClient is an alias for pps.APIClient.

type ProxyClient

type ProxyClient proxy.APIClient

ProxyClient is an alias of proxy.APIClient

type PutFileOption

type PutFileOption func(*putFileConfig)

PutFileOption configures a PutFile call.

func WithAppendPutFile

func WithAppendPutFile() PutFileOption

WithAppendPutFile configures the PutFile call to append to existing files.

func WithDatumPutFile

func WithDatumPutFile(datum string) PutFileOption

WithDatumPutFile configures the PutFile call to apply to a particular datum.

func WithImportConcurrency

func WithImportConcurrency(importConcurrency uint32) PutFileOption

WithImportConcurrency configures the maximum number of tasks in flight created by PutFileURL.

type TransactionAPIClient

type TransactionAPIClient transaction.APIClient

TransactionAPIClient is an alias of transaction.APIClient

type TransactionBuilder

type TransactionBuilder struct {
	APIClient
	// contains filtered or unexported fields
}

TransactionBuilder presents the same interface as a pachyderm APIClient, but captures requests rather than sending to the server. If a request is not supported by the transaction system, it immediately errors.

func (*TransactionBuilder) Close

func (tb *TransactionBuilder) Close() error

Close does not exist on a TransactionBuilder because it doesn't represent ownership of a connection to the API server. We need this to shadow the inherited Close, though.

func (*TransactionBuilder) GetAddress

func (tb *TransactionBuilder) GetAddress() *grpcutil.PachdAddress

GetAddress should not exist on a TransactionBuilder because it doesn't represent ownership of a connection to the API server, but it also doesn't return an error, so we just passthrough to the parent client's implementation.

type VersionAPIClient

type VersionAPIClient versionpb.APIClient

VersionAPIClient is an alias of versionpb.APIClient

Directories

Path Synopsis
Package limit provides primitives to limit concurrency.
Package limit provides primitives to limit concurrency.

Jump to

Keyboard shortcuts

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