list

package
v1.8.1 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type JobListWriter

type JobListWriter struct {
	// Output configuration options.
	ShowLocalJobs bool
	OutputJSON    bool

	Store Store     // Client to retrieve application configuration and job metadata.
	Ws    Workspace // Client to retrieve local jobs.
	Out   io.Writer // The writer where output will be written.
}

JobListWriter holds all the metadata and clients needed to list all jobs in a given workspace or app in a human- or machine-readable format.

func (*JobListWriter) Write

func (l *JobListWriter) Write(appName string) error

Jobs lists all jobs, either locally or in the workspace, and writes the output to a writer.

type Store

type Store interface {
	GetApplication(appName string) (*config.Application, error)
	ListJobs(appName string) ([]*config.Workload, error)
	ListServices(appName string) ([]*config.Workload, error)
}

Store wraps the methods required for interacting with config stores.

type SvcListWriter

type SvcListWriter struct {
	ShowLocalSvcs bool
	OutputJSON    bool

	Store Store     // Client to retrieve application configuration and service metadata.
	Ws    Workspace // Client to retrieve local jobs.
	Out   io.Writer // The writer where output will be written.
}

SvcListWriter holds all the metadata and clients needed to list all services in a given workspace or app in a human- or machine-readable format.

func (*SvcListWriter) Write

func (l *SvcListWriter) Write(appName string) error

Write lists all services, either locally or in the workspace, and writes the output to a writer.

type Workspace

type Workspace interface {
	JobNames() ([]string, error)
	ServiceNames() ([]string, error)
}

Workspace wraps the methods required to interact with a local workspace.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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