Documentation ¶
Overview ¶
Announce announces to the network that this node has joined It does so by telling the first seed node it finds active
Cron.go - deal with all things that should happen occassionally
Filename manipulation routines initially written on 5/6/17 Try and prevent spamming by limiting the number of request to once every 10 seconds (unless someeone else connects) This function is only set for External connectionings in run.go
Index ¶
- Constants
- Variables
- func CheckPeers()
- func CheckWallet(serverIP string) string
- func CronDaily()
- func CronHourly()
- func DB(c chan string)
- func FindNodeIP(nodeIP string) string
- func FlushPeerMap() error
- func PeerAdd(pi *PeerInfo) string
- func PeerDelete(key string) error
- func PeerListAll() string
- func PeerListExt() string
- func Run(c chan bool)
- func SendFile(address string, filename string)
- func Status() string
- func Wallet(c chan string, check bool)
- type PeerInfo
Constants ¶
View Source
const MaxIPsOrMacs int = 50
View Source
const PeersBucket = "PeersBucket"
Variables ¶
View Source
var FarmerMutex sync.Mutex
View Source
var LastConnectTime time.Time
View Source
var LastRemoteAddr string
View Source
var PeerIP map[string]int // Indexed by HostID
View Source
var PeerMac map[string]int // Indexed by Mac Address
View Source
var PeerMap struct { PL util.PeerList // contains filtered or unexported fields }
Functions ¶
func CheckPeers ¶
func CheckPeers()
func CheckWallet ¶
func CronHourly ¶
func CronHourly()
func FindNodeIP ¶
func FlushPeerMap ¶
func FlushPeerMap() error
func PeerDelete ¶
func PeerListAll ¶
func PeerListAll() string
func PeerListExt ¶
func PeerListExt() string
Types ¶
Click to show internal directories.
Click to hide internal directories.