mirror of
https://github.com/kaspanet/kaspad.git
synced 2025-06-24 15:02:32 +00:00

* Extract syncPruningPointUTXOSet to a separate method. * Implement logic to send pruning point utxo set chunks in a loop. * Replace IBDRootUTXOSetAndBlockMessage with IbdRootUtxoSetChunkMessage. * Add a new message: RequestNextIBDRootUTXOSetChunk. * Add a new message: DoneIBDRootUTXOSetChunks. * Protect HandleRequestIBDRootUTXOSetAndBlock from rogue messages. * Reimplement receiveIBDRootUTXOSetAndBlock. * Add CmdDoneIBDRootUTXOSetChunks to the HandleRelayInvs flow. * Decrease the max message size to 10mb. * Fix bad step. * Fix confusion between outgoing/incoming routes. * Measure how long it takes to send/receive the UTXO set. * Use LogAndMeasure in handleRequestIBDRootUTXOSetAndBlockFlow.
20 lines
511 B
Go
20 lines
511 B
Go
package appmessage
|
|
|
|
// MsgIBDRootUTXOSetChunk represents a kaspa IBDRootUTXOSetChunk message
|
|
type MsgIBDRootUTXOSetChunk struct {
|
|
baseMessage
|
|
Chunk []byte
|
|
}
|
|
|
|
// Command returns the protocol command string for the message
|
|
func (msg *MsgIBDRootUTXOSetChunk) Command() MessageCommand {
|
|
return CmdIBDRootUTXOSetChunk
|
|
}
|
|
|
|
// NewMsgIBDRootUTXOSetChunk returns a new MsgIBDRootUTXOSetChunk.
|
|
func NewMsgIBDRootUTXOSetChunk(chunk []byte) *MsgIBDRootUTXOSetChunk {
|
|
return &MsgIBDRootUTXOSetChunk{
|
|
Chunk: chunk,
|
|
}
|
|
}
|