connor

package
v0.4.7 Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2018 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewEngine

func NewEngine(ctx context.Context, cfg *Config, price price.Provider, log *zap.Logger, cc *grpc.ClientConn) *engine

Types

type Benchmarks

type Benchmarks sonm.Benchmarks

type Config

type Config struct {
	Node          nodeConfig         `yaml:"node"`
	Eth           accounts.EthConfig `yaml:"ethereum"`
	Market        marketConfig       `yaml:"market"`
	Mining        miningConfig       `yaml:"mining"`
	Log           logging.Config     `yaml:"log"`
	Engine        engineConfig       `yaml:"engine"`
	BenchmarkList benchmarks.Config  `yaml:"benchmarks"`
	AntiFraud     antifraud.Config   `yaml:"antifraud"`

	Metrics string `yaml:"metrics" default:"127.0.0.1:14005"`
}

func NewConfig

func NewConfig(path string) (*Config, error)

type Connor

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

func New

func New(ctx context.Context, cfg *Config, log *zap.Logger) (*Connor, error)

func (*Connor) Serve

func (c *Connor) Serve(ctx context.Context) error

type Corder

type Corder struct {
	*sonm.Order
	// contains filtered or unexported fields
}

func NewCorderFromOrder

func NewCorderFromOrder(order *sonm.Order, token string) *Corder

func NewCorderFromParams

func NewCorderFromParams(token string, price *big.Int, hashrate uint64, bench *Benchmarks) (*Corder, error)

func NewCordersSlice

func NewCordersSlice(orders []*sonm.Order, token string) []*Corder

func (*Corder) AsBID

func (co *Corder) AsBID() *sonm.BidOrder

func (*Corder) GetHashrate

func (co *Corder) GetHashrate() uint64

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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