Documentation
¶
Index ¶
- Variables
- func CheckCommonBlocks(c *gin.Context)
- func CheckIfChainLoading() gin.HandlerFunc
- func CheckNetworkHeaders() gin.HandlerFunc
- func ReceiveBlocks(c *gin.Context)
- func ReceiveTransactions(c *gin.Context)
- func SendAutoConfigureParams(c *gin.Context)
- func SendHeight(c *gin.Context)
- func SendPeerList(c *gin.Context)
- func SendPeerStatus(c *gin.Context)
- func SendTransactions(c *gin.Context)
- func SyncBlockChain(blockChainHeight int)
Constants ¶
This section is empty.
Variables ¶
var ArkAPIClient *core.ArkClient
ArkAPIClient - using to talk with other nodes with the ARK-GO Client API
var ArkNodeDB *storm.DB
ArkNodeDB interface is setup in goark-node.go. interface is visible in the whole package api
var ChainSyncChannel chan int
ChainSyncChannel - to signalend execution of chain sync make() called somewhere else (buffered)
var IsBlockSaving bool
IsBlockSaving - Global locker (semaphore) - to ignore writes of secondly received blocks if the same... Important for eventhook api
var IsBlockchainSynced bool
IsBlockchainSynced - Global locker (semaphore) - to ignore writes and receive blocks if blocks arent at the height
var SaveBlockMutex = &sync.RWMutex{}
SaveBlockMutex to be wrapped around sync threads
var SyncMutex = &sync.RWMutex{}
SyncMutex to be wrapped around sync threads
Functions ¶
func CheckCommonBlocks ¶
func CheckIfChainLoading ¶
func CheckIfChainLoading() gin.HandlerFunc
CheckIfChainLoading check on middleware level Function setup in goark-node.go -InitRoutes method
func CheckNetworkHeaders ¶
func CheckNetworkHeaders() gin.HandlerFunc
CheckNetworkHeaders check on middleware level Function setup in goark-node.go -InitRoutes method
func ReceiveTransactions ¶
ReceiveTransactions Returns a list of peers to client call. Response is in JSON
func SendAutoConfigureParams ¶
SendAutoConfigureParams - send autoconfigure parameters
func SendPeerList ¶
SendPeerList Returns a list of peers to client call. Response is in JSON
func SendPeerStatus ¶
SendPeerStatus respondes to other peers about node statuts
func SendTransactions ¶
SendTransactions Returns a list of peers to client call. Response is in JSON
func SyncBlockChain ¶
func SyncBlockChain(blockChainHeight int)
SyncBlockChain syncs blockchain to the lastest block it is run when starting the node
Types ¶
This section is empty.