Skip to content
Open
Show file tree
Hide file tree
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
15 changes: 10 additions & 5 deletions consensus/consensus-types/src/opt_proposal_msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,11 +108,16 @@ impl OptProposalMsg {
sender
);

self.block_data()
.payload()
.verify(validator, proof_cache, quorum_store_enabled)?;

self.block_data().grandparent_qc().verify(validator)?;
let (payload_verify_result, qc_verify_result) = rayon::join(
|| {
self.block_data()
.payload()
.verify(validator, proof_cache, quorum_store_enabled)
},
|| self.block_data().grandparent_qc().verify(validator),
);
payload_verify_result?;
qc_verify_result?;

// Note that we postpone the verification of SyncInfo until it's being used.
self.block_data.verify_well_formed()
Expand Down
3 changes: 1 addition & 2 deletions consensus/src/quorum_store/batch_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -545,8 +545,6 @@ impl<T: QuorumStoreSender + Clone + Send + Sync + 'static> BatchReaderImpl<T> {
let responders = Arc::new(Mutex::new(responders));
let responders_clone = responders.clone();

let subscriber_rx = self.batch_store.subscribe(*batch_info.digest());

let inflight_requests_clone = self.inflight_fetch_requests.clone();
let batch_store = self.batch_store.clone();
let requester = self.batch_requester.clone();
Expand All @@ -561,6 +559,7 @@ impl<T: QuorumStoreSender + Clone + Send + Sync + 'static> BatchReaderImpl<T> {
} else {
// Quorum store metrics
counters::MISSED_BATCHES_COUNT.inc();
let subscriber_rx = batch_store.subscribe(*batch_info.digest());
let payload = requester
.request_batch(
batch_digest,
Expand Down
Loading