Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify godoc for write batching #142

Merged
merged 1 commit into from
Jan 17, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions shim/interfaces.go
Original file line number Diff line number Diff line change
Expand Up @@ -375,10 +375,16 @@ type ChaincodeStubInterface interface {
// but accumulate in the cache. The cache is sent in large batches either at the end of transaction
// execution or after the FinishWriteBatch call.
// IMPORTANT: in this mode, the expected order of transaction execution and expected errors can be changed.
//
// If write batching is not supported by the peer, this method has no effect
// and writes to the ledger continue to be processed immediately.
StartWriteBatch()

// FinishWriteBatch sends accumulated changes in large batches to the peer
// if StartWriteBatch has been called before it.
//
// If write batching is not supported by the peer or no write batch has been
// started, this method has no effect and returns nil.
FinishWriteBatch() error
}

Expand Down
Loading