Version: v0.0.0-...-bc3f6f8 Latest Latest

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

Go to latest
Published: Sep 10, 2019 License: Apache-2.0 Imports: 19 Imported by: 0



Package platform contains interface and implementation to run a Handel node on multiple platforms. Such implementations include Localhost (run your test locally).



This section is empty.


This section is empty.


func DefaultStats

func DefaultStats(run int, nodes int, threshold int, network string) *monitor.Stats

DefaultStats returns default stats


type Command

type Command struct {
	// contains filtered or unexported fields

Command is a wrapper around Go's Cmd that can also output the log on demand

func NewCommand

func NewCommand(cmd string, args ...string) *Command

NewCommand returns a command that can outputs its stdout and stderr

func (*Command) LineOutput

func (c *Command) LineOutput() chan string

LineOutput continuously reads the stdout + stderr buffer and sends line by line output on the channel

func (*Command) ReadAll

func (c *Command) ReadAll() string

ReadAll returns stdout read entirely

type Platform

type Platform interface {
	// + the initial configuration of all structures needed for the platform
	// + building the binaries if needed and deploying them if needed
	Configure(*lib.Config) error
	// Makes sure that there is no part of the application still running
	Cleanup() error
	// Start runs an experiment from this run config, which is at the given
	// index in the Config. Both informations are redundant however it avoids
	// one useless step for each platform. Any implementations MUST perform this
	// experiment a number of times as defined in the Config struct field
	// Retrials. It must be a blocking call that returns only when the
	// experiment is finished.
	Start(idx int, rc *lib.RunConfig) error

Platform interface that has to be implemented to add another simulation- platform.

func NewAws

func NewAws(aws aws.Manager, awsConfig *aws.Config) Platform

NewAws creates AWS Platform

func NewLocalhost

func NewLocalhost() Platform

NewLocalhost returns a Platform that is executing binaries on localhost

func NewPlatform

func NewPlatform(t string, awsConfig string) Platform

NewPlatform returns the appropriate platform [deterlab,localhost] and setups the Cleanup call in case of a signal interruption

type Proc

type Proc struct {
	// contains filtered or unexported fields

Proc implements the lib.Platform interface for the process

func (*Proc) String

func (p *Proc) String() string


Path Synopsis

Jump to

Keyboard shortcuts

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