fix typos in ledge code comments (#23068)

This commit is contained in:
HaoranYi 2022-02-10 21:43:44 -06:00 committed by GitHub
parent 59e64d5e99
commit e4a1799334
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 7 additions and 7 deletions

View File

@ -16,7 +16,7 @@ pub enum BlockError {
InvalidLastTick,
/// Blocks can not have missing ticks
/// Usually indicates that the node was interruppted with a more valuable block during
/// Usually indicates that the node was interrupted with a more valuable block during
/// production and abandoned it for that more-favorable block. Leader sent data to indicate
/// the end of the block.
#[error("too few ticks")]

View File

@ -1254,7 +1254,7 @@ impl Blockstore {
/// - `index_meta_time`: the time spent on loading or creating the
/// index meta entry from the db.
/// - `is_trusted`: if false, this function will check whether the
/// input shred is dupliate.
/// input shred is duplicate.
/// - `handle_duplicate`: the function that handles duplication.
/// - `leader_schedule`: the leader schedule will be used to check
/// whether it is okay to insert the input shred.
@ -3472,7 +3472,7 @@ fn commit_slot_meta_working_set(
///
/// 1) Finds the slot metadata in the cache of dirty slot metadata we've
/// previously touched, otherwise:
/// 2) Searchs the database for that slot metadata. If still no luck, then:
/// 2) Searches the database for that slot metadata. If still no luck, then:
/// 3) Create a dummy orphan slot in the database.
///
/// Also see [`find_slot_meta_in_cached_state`] and [`find_slot_meta_in_db_else_create`].
@ -3685,7 +3685,7 @@ fn handle_chaining_for_slot(
/// `slot_meta`: the SlotMeta of the above `slot`.
/// `working_set`: a slot-id to SlotMetaWorkingSetEntry map which is used
/// to traverse the graph.
/// `passed_visisted_slots`: all the traversed slots which have passed the
/// `passed_visited_slots`: all the traversed slots which have passed the
/// slot_function. This may also include the input `slot`.
/// `slot_function`: a function which updates the SlotMeta of the visisted
/// slots and determine whether to further traverse the children slots of

View File

@ -428,7 +428,7 @@ impl Rocks {
// shorten it to a day (24 hours).
//
// As we write newer SST files over time at rather consistent rate of speed, this
// effectively makes each newly-created ssts be re-compacted for the filter at
// effectively makes each newly-created sets be re-compacted for the filter at
// well-dispersed different timings.
// As a whole, we rewrite the whole dataset at every PERIODIC_COMPACTION_SECONDS,
// slowly over the duration of PERIODIC_COMPACTION_SECONDS. So, this results in
@ -1559,7 +1559,7 @@ pub mod tests {
CompactionDecision::Keep
));
// mutating oledst_slot doen't affect existing compaction filters...
// mutating oldest_slot doesn't affect existing compaction filters...
oldest_slot.set(1);
assert!(matches!(
compaction_filter.filter(dummy_level, &key, &dummy_value),

View File

@ -66,7 +66,7 @@ use {
};
// it tracks the block cost available capacity - number of compute-units allowed
// by max blockl cost limit
// by max block cost limit
#[derive(Debug)]
pub struct BlockCostCapacityMeter {
pub capacity: u64,