mirror of
https://github.com/kaspanet/kaspad.git
synced 2025-05-31 11:16:42 +00:00

* [NOD-1501] Add logAndMeasureExecutionTime to SyncManager methods. * [NOD-1501] Implement antiPastHashesBetween. * [NOD-1501] Implement createBlockLocator. * [NOD-1501] Implement findNextBlockLocatorBoundaries. * [NOD-1501] Rename IsBlockHeaderInPruningPointFutureAndVirtualPast to IsBlockInHeaderPruningPointFutureAndVirtualPast. * [NOD-1501] Add GetSyncInfo. * [NOD-1501] Make go vet happy. * [NOD-1501] Rename sync states. * [NOD-1501] Move maxHashesInGetHashesBetween to antipast.go. * [NOD-1501] Rename maxHashesInAntiPastHashesBetween. * [NOD-1501] Implement LowestChainBlockAboveOrEqualToBlueScore. * [NOD-1501] Fix bad variable name. * [NOD-1501] Fix LowestChainBlockAboveOrEqualToBlueScore. * [NOD-1501] Clarify LowestChainBlockAboveOrEqualToBlueScore.
20 lines
476 B
Go
20 lines
476 B
Go
package externalapi
|
|
|
|
// Each of the following represent one of the possible sync
|
|
// states of the consensus
|
|
const (
|
|
SyncStateNormal SyncState = iota
|
|
SyncStateMissingUTXOSet
|
|
SyncStateHeadersFirst
|
|
SyncStateMissingBlockBodies
|
|
)
|
|
|
|
// SyncState represents the current sync state of the consensus
|
|
type SyncState uint8
|
|
|
|
// SyncInfo holds info about the current sync state of the consensus
|
|
type SyncInfo struct {
|
|
State SyncState
|
|
IBDRootUTXOBlockHash *DomainHash
|
|
}
|