batchchunker

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 26, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BatchMaker

type BatchMaker struct {
	// contains filtered or unexported fields
}

BatchMaker struct

func NewBatch

func NewBatch(ar *transactor.Transactor, w *wallet.Wallet, reader io.Reader, totalSize int64) *BatchMaker

NewBatch creates a NewBatch struct

func (*BatchMaker) SendBatchTransaction

func (b *BatchMaker) SendBatchTransaction() ([]string, error)

SendBatchTransaction chunks, sends and waits for all the transactions to get mined

type ChunkInformation

type ChunkInformation struct {
	PreviousChunk string `json:"previous_chunk"`
	IsHead        bool   `json:"is_head"`
	Version       string `json:"version"`
	Position      int64  `json:"position"`
}

ChunkInformation is the extra data we add to the tags to inform us about the last chunk, it's position, whether it's the head of the chunk and it's data version

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL