Skip to content

Commit

Permalink
Added control plane logs
Browse files Browse the repository at this point in the history
  • Loading branch information
fulmicoton committed Mar 13, 2024
1 parent dbedc29 commit 996f06d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions quickwit/quickwit-control-plane/src/control_plane.rs
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,7 @@ impl Handler<DeleteIndexRequest> for ControlPlane {
ctx: &ActorContext<Self>,
) -> Result<Self::Reply, ActorExitStatus> {
let index_uid: IndexUid = request.index_uid().clone();
info!(index=%index_uid, "delete index");

if let Err(metastore_error) = self.metastore.delete_index(request).await {
return convert_metastore_error(metastore_error);
Expand Down Expand Up @@ -557,6 +558,8 @@ impl Handler<AddSourceRequest> for ControlPlane {
return Ok(Err(ControlPlaneError::from(error)));
}
};
info!(index=%index_uid, source_config=?source_config, "add source");

if let Err(error) = self.metastore.add_source(request).await {
return Ok(Err(ControlPlaneError::from(error)));
};
Expand Down Expand Up @@ -589,6 +592,8 @@ impl Handler<ToggleSourceRequest> for ControlPlane {
let source_id = request.source_id.clone();
let enable = request.enable;

info!(index=%index_uid, source_id=%source_id, enable=enable, "toggle source");

if let Err(error) = self.metastore.toggle_source(request).await {
return Ok(Err(ControlPlaneError::from(error)));
};
Expand Down

0 comments on commit 996f06d

Please sign in to comment.