Documentation ¶
Index ¶
- Variables
- func AddRequestBackpressureSignal(reqFunc func() bool)
- func BroadcastHeartbeat()
- func BroadcastLatestMilestoneRequest()
- func BroadcastMilestoneRequests(rangeToRequest int, onExistingMilestoneInRange func(index milestone.Index), ...) int
- func BroadcastQueue() bqueue.Queue
- func MemoizedRequestMissingMilestoneApprovees(preventDiscard ...bool) func(ms milestone.Index)
- func Processor() *processor.Processor
- func Request(hash hornet.Hash, msIndex milestone.Index, preventDiscard ...bool) bool
- func RequestApprovees(cachedTx *tangle.CachedTransaction, msIndex milestone.Index, ...)
- func RequestMilestoneApprovees(cachedMsBndl *tangle.CachedBundle) bool
- func RequestMultiple(hashes hornet.Hashes, msIndex milestone.Index, preventDiscard ...bool) int
- func RequestQueue() rqueue.Queue
Constants ¶
This section is empty.
Variables ¶
var (
PLUGIN = node.NewPlugin("Gossip", node.Enabled, configure, run)
)
Functions ¶
func AddRequestBackpressureSignal ¶
func AddRequestBackpressureSignal(reqFunc func() bool)
func BroadcastHeartbeat ¶
func BroadcastHeartbeat()
BroadcastHeartbeat broadcasts a heartbeat message to every connected peer who supports STING.
func BroadcastLatestMilestoneRequest ¶
func BroadcastLatestMilestoneRequest()
BroadcastLatestMilestoneRequest broadcasts a milestone request for the latest milestone every connected peer who supports STING.
func BroadcastMilestoneRequests ¶
func BroadcastMilestoneRequests(rangeToRequest int, onExistingMilestoneInRange func(index milestone.Index), from ...milestone.Index) int
BroadcastMilestoneRequests broadcasts up to N requests for milestones nearest to the current solid milestone index to every connected peer who supports STING. Returns the number of milestones requested.
func BroadcastQueue ¶
BroadcastQueue returns the broadcast queue instance of the gossip plugin.
func MemoizedRequestMissingMilestoneApprovees ¶
MemoizedRequestMissingMilestoneApprovees returns a function which traverses the approvees of a given milestone and requests each missing approvee. As a special property, invocations of the yielded function share the same 'already traversed' set to circumvent requesting the same approvees multiple times.
func Request ¶
Request enqueues a request to the request queue for the given transaction if it isn't a solid entry point and is not contained in the database already.
func RequestApprovees ¶
func RequestApprovees(cachedTx *tangle.CachedTransaction, msIndex milestone.Index, preventDiscard ...bool)
RequestApprovees enqueues requests for the approvees of the given transaction to the request queue, if the given transaction is not a solid entry point and neither its approvees are and also not in the database.
func RequestMilestoneApprovees ¶
func RequestMilestoneApprovees(cachedMsBndl *tangle.CachedBundle) bool
RequestMilestoneApprovees enqueues requests for the approvees of the given milestone bundle to the request queue, if the approvees are not solid entry points and not already in the database.
func RequestMultiple ¶
RequestMultiple works like Request but takes multiple transaction hashes.
func RequestQueue ¶
RequestQueue returns the request queue instance of the gossip plugin.
Types ¶
This section is empty.