Skip to content

Commit c6fa475

Browse files
committed
Fix poor naming
1 parent f6cb417 commit c6fa475

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

quickwit/quickwit-ingest/src/ingest_v2/ingester.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,7 @@ impl Ingester {
514514
continue;
515515
}
516516
let doc_mapper = shard.doc_mapper_opt.clone().expect("shard should be open");
517-
let validate_shard = shard.validate;
517+
let validate_docs = shard.validate_docs;
518518
let follower_id_opt = shard.follower_id_opt().cloned();
519519
let from_position_exclusive = shard.replication_position_inclusive.clone();
520520

@@ -570,7 +570,7 @@ impl Ingester {
570570
// Total number of bytes (valid and invalid documents)
571571
let original_batch_num_bytes = doc_batch.num_bytes() as u64;
572572

573-
let (valid_doc_batch, parse_failures) = if validate_shard {
573+
let (valid_doc_batch, parse_failures) = if validate_docs {
574574
validate_doc_batch(doc_batch, doc_mapper).await?
575575
} else {
576576
(doc_batch, Vec::new())

quickwit/quickwit-ingest/src/ingest_v2/models.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ pub(super) struct IngesterShard {
5252
pub doc_mapper_opt: Option<Arc<DocMapper>>,
5353
/// Whether to validate documents in this shard. True if no preprocessing (VRL) will happen
5454
/// before indexing.
55-
pub validate: bool,
55+
pub validate_docs: bool,
5656
pub shard_status_tx: watch::Sender<ShardStatus>,
5757
pub shard_status_rx: watch::Receiver<ShardStatus>,
5858
/// Instant at which the shard was last written to.
@@ -67,7 +67,7 @@ impl IngesterShard {
6767
truncation_position_inclusive: Position,
6868
doc_mapper: Arc<DocMapper>,
6969
now: Instant,
70-
validate: bool,
70+
validate_docs: bool,
7171
) -> Self {
7272
let shard_status = (shard_state, replication_position_inclusive.clone());
7373
let (shard_status_tx, shard_status_rx) = watch::channel(shard_status);
@@ -78,7 +78,7 @@ impl IngesterShard {
7878
truncation_position_inclusive,
7979
is_advertisable: false,
8080
doc_mapper_opt: Some(doc_mapper),
81-
validate,
81+
validate_docs,
8282
shard_status_tx,
8383
shard_status_rx,
8484
last_write_instant: now,
@@ -103,7 +103,7 @@ impl IngesterShard {
103103
// anyway.
104104
is_advertisable: false,
105105
doc_mapper_opt: None,
106-
validate: false,
106+
validate_docs: false,
107107
shard_status_tx,
108108
shard_status_rx,
109109
last_write_instant: now,
@@ -116,7 +116,7 @@ impl IngesterShard {
116116
truncation_position_inclusive: Position,
117117
doc_mapper_opt: Option<Arc<DocMapper>>,
118118
now: Instant,
119-
validate: bool,
119+
validate_docs: bool,
120120
) -> Self {
121121
let shard_status = (shard_state, replication_position_inclusive.clone());
122122
let (shard_status_tx, shard_status_rx) = watch::channel(shard_status);
@@ -127,7 +127,7 @@ impl IngesterShard {
127127
truncation_position_inclusive,
128128
is_advertisable: false,
129129
doc_mapper_opt,
130-
validate,
130+
validate_docs,
131131
shard_status_tx,
132132
shard_status_rx,
133133
last_write_instant: now,

0 commit comments

Comments
 (0)