Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
from sqlalchemy.ext.asyncio import AsyncSession

from dstack._internal.core.models.configurations import (
DEFAULT_REPLICA_GROUP_NAME,
ServiceConfiguration,
)
from dstack._internal.core.models.runs import JobStatus, JobTerminationReason, RunSpec
Expand All @@ -33,15 +32,6 @@ def compute_desired_replica_counts(
prev_counts: PerGroupDesiredCounts = (
json.loads(run_model.desired_replica_counts) if run_model.desired_replica_counts else {}
)
if (
prev_counts == {}
and len(replica_groups) == 1
and replica_groups[0].name == DEFAULT_REPLICA_GROUP_NAME
):
# Special case to avoid dropping the replica count to group.replicas.min
# when a 0.20.7+ server first processes a service created by a pre-0.20.7 server.
# TODO: remove once most users upgrade to 0.20.7+.
prev_counts = {DEFAULT_REPLICA_GROUP_NAME: run_model.desired_replica_count}
desired_counts: PerGroupDesiredCounts = {}
total = 0
for group in replica_groups:
Expand Down
Loading