Skip to content

Add instance to affinity group popup should list only stopped instances #2794

@askfongjojo

Description

@askfongjojo

When attempting to add an instance that isn't in the stopped state to an affinity group, user gets an error:

error; status code: 400 Bad Request
{
  "error_code": "InvalidRequest",
  "message": "Instance cannot be added to anti-affinity group with reservation",
  "request_id": "dbcaf573-733e-49ba-8031-47108c238c97"
}
error

On the console, although the instance picker mentions the state restriction, user is still allowed to select and click on the "Add to Group" button but the end result is a no-op. It can be a bit confusing. Ideally, we filter out those ineligible instances in the first place. If it's hard to do for some reason, returning a message or disabling the add button is still better than no UI response.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions