Skip to content

Commit

Permalink
Release lock when return function
Browse files Browse the repository at this point in the history
Signed-off-by: Cai Zhang <[email protected]>
  • Loading branch information
xiaocai2333 committed Dec 30, 2024
1 parent 56c5b66 commit fc1d147
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions internal/datacoord/compaction.go
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ func (c *compactionPlanHandler) schedule() []CompactionTask {

c.executingGuard.Lock()
if len(c.executingTasks) >= parallelism {
c.executingGuard.Unlock()

Check warning on line 217 in internal/datacoord/compaction.go

View check run for this annotation

Codecov / codecov/patch

internal/datacoord/compaction.go#L217

Added line #L217 was not covered by tests
return selected
}
c.executingGuard.Unlock()
Expand Down

0 comments on commit fc1d147

Please sign in to comment.