recovery

package
v0.0.0-...-e560ebb Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2021 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Overview

Package recovery provides ability to run recovery tasks against on the target units.

Index

Constants

View Source
const (
	PlanRepairDUT        = "repair_dut"
	PlanRepairServo      = "repair_servo"
	PlanRepairLabstation = "repair_labstation"
	PlanRepairJetstream  = "repair_jetstream"
)

List of predefined plans. TODO(otabek@): Update list of plans and mapping with final version.

Variables

This section is empty.

Functions

func NewLocalTLWAccess

func NewLocalTLWAccess(ufs localtlw.UFSClient, csac localtlw.CSAClient) (tlw.Access, error)

NewLocalTLWAccess provides instance of local implementation of TLW Access.

func Run

func Run(ctx context.Context, args *RunArgs) error

Run runs the recovery tasks against the provide unit. Process includes:

  • Verification of input data.
  • Set logger.
  • Collect DUTs info.
  • Load execution plan for required task with verification.
  • Send DUTs info to inventory.

Types

type RunArgs

type RunArgs struct {
	Access tlw.Access
	// UnitName represents some device setup against which running some tests or task in the system.
	// The unit can be represented as a single DUT or group of the DUTs registered in inventory as single unit.
	UnitName string
	// Provide access to read custom plans outside recovery. The default plans with actions will be ignored.
	ConfigReader io.Reader
	// Logger prints message to the logs.
	Logger logger.Logger
}

RunArgs holds input arguments for recovery process.

Directories

Path Synopsis
internal
config
Package config provides struts to holds and read configs.
Package config provides struts to holds and read configs.
localtlw
Package localtlw provides local implementation of TLW Access.
Package localtlw provides local implementation of TLW Access.
localtlw/dutinfo
Package dutinfo provides help function to work with DUT info.
Package dutinfo provides help function to work with DUT info.
localtlw/servod
Package servod provides functions to manage connection and communication with servod daemon on servo-host.
Package servod provides functions to manage connection and communication with servod daemon on servo-host.
localtlw/xmlrpc
Package xmlrpc implements the XML-RPC client library.
Package xmlrpc implements the XML-RPC client library.
log
Package log provides a wrapper over logging interfaces to simplify usage in recovery lib.
Package log provides a wrapper over logging interfaces to simplify usage in recovery lib.
plan
Package plan provides struts and functionality to use plans and actions.
Package plan provides struts and functionality to use plans and actions.
plan/execs
Package execs provides collection of execution functions for actions and ability to execute them.
Package execs provides collection of execution functions for actions and ability to execute them.
retry
Package retry provides retry methods.
Package retry provides retry methods.
Package logger provides an abstract representation of logging interfaces used by recovery lib.
Package logger provides an abstract representation of logging interfaces used by recovery lib.
Package tlw provides an abstract representation of the TLW API which is used by recovery
Package tlw provides an abstract representation of the TLW API which is used by recovery

Jump to

Keyboard shortcuts

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