Skip to content

Commit

Permalink
chore: apply suggestions from CR
Browse files Browse the repository at this point in the history
  • Loading branch information
WenyXu committed Jan 4, 2024
1 parent aa2d4bb commit 817b650
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/metric-engine/src/engine/alter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,9 @@ impl MetricEngineInner {
region_id: RegionId,
request: RegionAlterRequest,
) -> Result<AffectedRows> {
let is_altering_logical_region = self
.state
.read()
.await
.physical_regions()
.contains_key(&region_id);
let is_altering_physical_region = self.is_physical_region(region_id).await;

let result = if is_altering_logical_region {
let result = if is_altering_physical_region {
self.alter_physical_region(region_id, request).await
} else {
self.alter_logical_region(region_id, request).await
Expand Down

0 comments on commit 817b650

Please sign in to comment.