api

package
v0.0.0-...-e607a19 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2016 License: BSD-2-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const TimeBetweenCalls = 5

TimeBetweenCalls is number of seconds a client needs to wait before being able to request new work

Variables

This section is empty.

Functions

This section is empty.

Types

type PoolAPI

type PoolAPI struct {
	//Fee is the poolfee in 0.01%
	Fee int
	//ShareChain for getting work and posting shares
	ShareChain *sharechain.ShareChain
}

PoolAPI implements the http handlers

func (*PoolAPI) FeeHandler

func (pa *PoolAPI) FeeHandler(w http.ResponseWriter, r *http.Request)

FeeHandler writes the fee applied by the pool

func (*PoolAPI) GetWorkHandler

func (pa *PoolAPI) GetWorkHandler(w http.ResponseWriter, r *http.Request)

GetWorkHandler returns a header to the miners to work on

func (*PoolAPI) SubmitHeaderHandler

func (pa *PoolAPI) SubmitHeaderHandler(w http.ResponseWriter, r *http.Request)

SubmitHeaderHandler is called by the miners to submit their shares A 204 is returned when successful

Jump to

Keyboard shortcuts

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