Skip to content
This repository was archived by the owner on Apr 22, 2025. It is now read-only.

Commit 0dd377e

Browse files
committed
FABJ-441 Proto updates
Change-Id: Ia120efdb13918e0b620ab28af5bf9ba3780f95f8 Signed-off-by: rickr <cr22rc@gmail.com>
1 parent 433432f commit 0dd377e

File tree

3 files changed

+23
-105
lines changed

3 files changed

+23
-105
lines changed

src/main/proto/orderer/ab.proto

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ message BroadcastResponse {
3030
string info = 2;
3131
}
3232

33-
message SeekNewest { }
33+
message SeekNewest {}
3434

35-
message SeekOldest { }
35+
message SeekOldest {}
3636

3737
message SeekSpecified {
3838
uint64 number = 1;
@@ -49,19 +49,33 @@ message SeekPosition {
4949
// SeekInfo specifies the range of requested blocks to return
5050
// If the start position is not found, an error is immediately returned
5151
// Otherwise, blocks are returned until a missing block is encountered, then behavior is dictated
52-
// by the SeekBehavior specified. If BLOCK_UNTIL_READY is specified, the reply will block until
53-
// the requested blocks are available, if FAIL_IF_NOT_READY is specified, the reply will return an
54-
// error indicating that the block is not found. To request that all blocks be returned indefinitely
55-
// as they are created, behavior should be set to BLOCK_UNTIL_READY and the stop should be set to
56-
// specified with a number of MAX_UINT64
52+
// by the SeekBehavior specified.
5753
message SeekInfo {
54+
// If BLOCK_UNTIL_READY is specified, the reply will block until the requested blocks are available,
55+
// if FAIL_IF_NOT_READY is specified, the reply will return an error indicating that the block is not
56+
// found. To request that all blocks be returned indefinitely as they are created, behavior should be
57+
// set to BLOCK_UNTIL_READY and the stop should be set to specified with a number of MAX_UINT64
5858
enum SeekBehavior {
5959
BLOCK_UNTIL_READY = 0;
6060
FAIL_IF_NOT_READY = 1;
6161
}
62-
SeekPosition start = 1; // The position to start the deliver from
63-
SeekPosition stop = 2; // The position to stop the deliver
62+
63+
// SeekErrorTolerance indicates to the server how block provider errors should be tolerated. By default,
64+
// if the deliver service detects a problem in the underlying block source (typically, in the orderer,
65+
// a consenter error), it will begin to reject deliver requests. This is to prevent a client from waiting
66+
// for blocks from an orderer which is stuck in an errored state. This is almost always the desired behavior
67+
// and clients should stick with the default STRICT checking behavior. However, in some scenarios, particularly
68+
// when attempting to recover from a crash or other corruption, it's desirable to force an orderer to respond
69+
// with blocks on a best effort basis, even if the backing consensus implementation is in an errored state.
70+
// In this case, set the SeekErrorResponse to BEST_EFFORT to ignore the consenter errors.
71+
enum SeekErrorResponse {
72+
STRICT = 0;
73+
BEST_EFFORT = 1;
74+
}
75+
SeekPosition start = 1; // The position to start the deliver from
76+
SeekPosition stop = 2; // The position to stop the deliver
6477
SeekBehavior behavior = 3; // The behavior when a missing block is encountered
78+
SeekErrorResponse error_response = 4; // How to respond to errors reported to the deliver service
6579
}
6680

6781
message DeliverResponse {

src/main/proto/orderer/configuration.proto

Lines changed: 0 additions & 87 deletions
This file was deleted.

src/main/proto/peer/peer.proto

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,6 @@ package protos;
2323
import "peer/proposal.proto";
2424
import "peer/proposal_response.proto";
2525

26-
message PeerID {
27-
string name = 1;
28-
}
29-
30-
message PeerEndpoint {
31-
PeerID id = 1;
32-
string address = 2;
33-
}
34-
3526
service Endorser {
3627
rpc ProcessProposal(SignedProposal) returns (ProposalResponse) {}
3728
}

0 commit comments

Comments
 (0)