Skip to content

Commit

Permalink
fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
gjcolombo committed Apr 12, 2023
1 parent cefcf42 commit 8977ba4
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions nexus/src/app/instance.rs
Original file line number Diff line number Diff line change
Expand Up @@ -411,10 +411,15 @@ impl super::Nexus {
// Users are allowed to request a start or stop even if the instance is
// already in the desired state (or moving to it), and we will issue a
// request to the SA to make the state change in these cases in case the
// runtime state we saw here was stale. However, users are not allowed
// to change the state of an instance that's migrating, failed or
// destroyed, except that multiple requests to migrate in are allowed
// for idempotency.
// runtime state we saw here was stale.
//
// Users cannot change the state of a failed or destroyed instance.
// TODO(#2825): Failed instances should be allowed to stop.
//
// Migrating instances can't change state until they're done migrating,
// but for idempotency, a request to make an incarnation of an instance
// into a migration target is allowed if the incarnation is already a
// migration target.
let allowed = match runtime.run_state {
InstanceState::Creating => true,
InstanceState::Starting => true,
Expand Down

0 comments on commit 8977ba4

Please sign in to comment.