Skip to content

Commit

Permalink
add todo note
Browse files Browse the repository at this point in the history
  • Loading branch information
sakoush committed Jan 28, 2025
1 parent 0d73987 commit 6170cdf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions scheduler/pkg/store/memory.go
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,8 @@ func (m *MemoryStore) updateLoadedModelsImpl(

// note that we use len(modelVersion.GetAssignment()) to calculate the number of replicas as the status of the model at this point might not reflect the actual number of replicas
// in modelVersion.state.AvailableReplicas (we call updateModelStatus later)

// TODO: the conditions here keep growing, refactor or consider a simpler check.
if replicaStateUpdated || modelVersion.state.State == ScheduleFailed || model.IsDeleted() || modelVersion.state.State == ModelProgressing ||
(modelVersion.state.State == ModelAvailable && len(modelVersion.GetAssignment()) < modelVersion.DesiredReplicas()) {
logger.Debugf("Updating model status for model %s server %s", modelKey, serverKey)
Expand Down

0 comments on commit 6170cdf

Please sign in to comment.