dutagent

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: BSD-2-Clause Imports: 9 Imported by: 0

Documentation

Overview

Package broker provides utilities for a dutagent service to handel the RPC requests.

Copyright 2024 Blindspot Software Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Copyright 2024 Blindspot Software Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Copyright 2024 Blindspot Software Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Deinit

func Deinit(devices dut.Devlist) error

Denit runs the Deinit function of all modules for all commands of the provided devices. All Deinit functions are called, even if an error occurs. In this case the an ModuleInitErr is returned that holds all errors reported by the modules.

func Init

func Init(devices dut.Devlist) error

Init runs the Init function of all modules for all commands of the provided devices. All init functions are called, even if an error occurs. In this case the an ModuleInitErr is returned that holds all errors reported by the modules.

Types

type Broker

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

Broker mediates between a module and its environment while the module is executed. This concerns communication and data exchange.

func (*Broker) Err

func (b *Broker) Err() <-chan error

func (*Broker) ModuleSession

func (b *Broker) ModuleSession() module.Session

func (*Broker) Start

func (b *Broker) Start(ctx context.Context, s Stream)

type ModuleInitError

type ModuleInitError struct {
	Errs []ModuleInitErrorDetails
	// contains filtered or unexported fields
}

ModuleInitError is a container for errors that occur during module initialization.

func (*ModuleInitError) Error

func (e *ModuleInitError) Error() string

type ModuleInitErrorDetails

type ModuleInitErrorDetails struct {
	Dev string
	Cmd string
	Mod dut.Module
	Err error
}

type Stream

type Stream interface {
	Send(msg *pb.RunResponse) error
	Receive() (*pb.RunRequest, error)
}

Jump to

Keyboard shortcuts

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