client

package module
v0.0.0-...-4a658a7 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: MIT Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

client

AFAIRE


Copyright (c) 2022-2023 Archivage Numérique

Documentation

Index

Constants

View Source
const (
	ErrCreated  = errors.Sentinel("job created")
	ErrReserved = errors.Sentinel("job reserved")
	ErrUpdated  = errors.Sentinel("job updated")
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

func New

func New(logger *logger.Logger, cfg *balancer.Config) (*Client, error)

func (*Client) CreateJob

func (cl *Client) CreateJob(ctx context.Context, jtc *sdk.JobToCreate) (*sdk.Job, error)

func (*Client) CreateWorkflow

func (cl *Client) CreateWorkflow(ctx context.Context, wtc *sdk.WorkflowToCreate) (*sdk.Workflow, *sdk.Job, error)

func (*Client) NextJob

func (cl *Client) NextJob(ctx context.Context, namespace, host, worker string) (*sdk.Job, error)

func (*Client) UpdateJob

func (cl *Client) UpdateJob(ctx context.Context, jtu *sdk.JobToUpdate) (*sdk.Job, *sdk.Job, error)

Jump to

Keyboard shortcuts

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