Skip to content

Commit

Permalink
Add doc_mapping_uid field to Shard
Browse files Browse the repository at this point in the history
  • Loading branch information
guilload committed Jun 19, 2024
1 parent 5b85f7c commit 892c5d5
Show file tree
Hide file tree
Showing 31 changed files with 290 additions and 892 deletions.
11 changes: 7 additions & 4 deletions quickwit/quickwit-control-plane/src/control_plane.rs
Original file line number Diff line number Diff line change
Expand Up @@ -785,9 +785,9 @@ impl Handler<GetOrCreateOpenShardsRequest> for ControlPlane {
.get_or_create_open_shards(request, &mut self.model, ctx.progress())
.await
{
Ok(resp) => {
Ok(response) => {
let _rebuild_plan_waiter = self.rebuild_plan_debounced(ctx);
Ok(Ok(resp))
Ok(Ok(response))
}
Err(metastore_error) => convert_metastore_error(metastore_error),
}
Expand Down Expand Up @@ -1055,7 +1055,7 @@ mod tests {
ListShardsResponse, ListShardsSubresponse, MetastoreError, MockMetastoreService,
OpenShardSubresponse, OpenShardsResponse, SourceType,
};
use quickwit_proto::types::Position;
use quickwit_proto::types::{DocMappingUid, Position};
use tokio::sync::Mutex;

use super::*;
Expand Down Expand Up @@ -1702,7 +1702,6 @@ mod tests {

#[tokio::test]
async fn test_fill_shard_table_position_from_metastore_on_startup() {
quickwit_common::setup_logging_for_tests();
let universe = Universe::with_accelerated_time();
let node_id = NodeId::new("control-plane-node".to_string());
let indexer_pool = IndexerPool::default();
Expand Down Expand Up @@ -1917,6 +1916,7 @@ mod tests {
leader_id: "node1".to_string(),
follower_id: None,
shard_state: ShardState::Open as i32,
doc_mapping_uid: Some(DocMappingUid::default()),
publish_position_inclusive: None,
publish_token: None,
}],
Expand Down Expand Up @@ -2046,6 +2046,7 @@ mod tests {
leader_id: "node1".to_string(),
follower_id: None,
shard_state: ShardState::Open as i32,
doc_mapping_uid: Some(DocMappingUid::default()),
publish_position_inclusive: None,
publish_token: None,
}],
Expand Down Expand Up @@ -2333,6 +2334,7 @@ mod tests {
leader_id: "test-ingester".to_string(),
follower_id: None,
shard_state: ShardState::Open as i32,
doc_mapping_uid: Some(DocMappingUid::default()),
publish_position_inclusive: Some(Position::Beginning),
publish_token: None,
}),
Expand Down Expand Up @@ -2486,6 +2488,7 @@ mod tests {
leader_id: "test-ingester".to_string(),
follower_id: None,
shard_state: ShardState::Open as i32,
doc_mapping_uid: Some(DocMappingUid::default()),
publish_position_inclusive: Some(Position::Beginning),
publish_token: None,
}),
Expand Down
Loading

0 comments on commit 892c5d5

Please sign in to comment.