Skip to content

Cleanup: Remove redundant API to change service offering for VMs #6150

Closed

Description

@nvazquez
ISSUE TYPE
  • Improvement Request
COMPONENT NAME
API
CLOUDSTACK VERSION
4.17.0-SNAPSHOT and above
CONFIGURATION
OS / ENVIRONMENT

N/A

SUMMARY

As investigated on #3110, PR #5008 had impact on two similar APIs for changing the service offering for a VM, resulting both on resizing the VM's ROOT volume (scaleVirtualMachine and changeServiceForVirtualMachine APIs)

The proposal is to remove the changeServiceForVirtualMachine API, since it is not used in the UI codebase, and the outcome of this API can be obtained by invoking scaleVirtualMachine.

Activity

  1. added this to the 4.18.0.0 milestone on Mar 21, 2022
  2. moved this to Backlog in ACS Backlogon Jul 6, 2022
  3. moved this from Backlog to 🏗 Assigned in ACS Backlogon Jul 6, 2022
  4. harikrishna-patnala commented on Jul 7, 2022

    @harikrishna-patnala
    Member

    Agree @nvazquez we can remove the API "changeServiceForVirtualMachine" since "scaleVirtualMachine" handles both stopped and running VM to change the offering.

    @DaanHoogland @sureshanaparti a quick suggestion is needed here please. Can I proceed with completely removing the API or using deprecate annotations? My only concern with deprecate annotation is I did not see any proper notification on deprecation when the API is used, so users may end up using it even after the deprecation.

  5. DaanHoogland commented on Jul 7, 2022

    @DaanHoogland
    Contributor

    @harikrishna-patnala for an API we can only annotate it and not prevent any usage of it. We should wait with removing it untill 5.0 if at all it comes. If scaleVirtualMachine allows for changing the service offering than we can mark changeServiceForVirtualMachine for removal and maybe cripple its functionality. We have more clients than the UI hwoever, so let's not remove it just yet (cmk, terraform, ...).

  6. GabrielBrascher commented on Jul 7, 2022

    @GabrielBrascher
    Member

    Agree with removing it. But also agree with @DaanHoogland. Removing it would cause API backwards compatibility and therefore requires a 5.0 (which would be fine for me).

    For a 4.X.Y we can deprecate it adding an annotation and also spreading the words via release notes, documentation etc.

  7. yadvr commented on Jul 7, 2022

    @yadvr
    Member

    One way to deprecate it would be to stop the API getting published via apidocs and use in UI (the API may still continue to be listed via cmk/listApis though), as well as add deprecation note in the Api cmd class description.

  8. harikrishna-patnala commented on Jul 7, 2022

    @harikrishna-patnala
    Member

    Thanks guys, I've raised a PR deprecating the API and updated the description, please review.

  9. moved this from 🏗 Assigned to Testing 🥼 in ACS Backlogon Jul 7, 2022
  10. yadvr commented on Jul 9, 2022

    @yadvr
    Member

    Fixed in #6540

  11. moved this from Testing 🥼 to ✅ Done in ACS Backlogon Jul 9, 2022
  12. moved this from ✅ Done to Last Sprint in ACS Backlogon Jul 13, 2022
  13. moved this from Last Sprint to Hari's List in ACS Backlogon Jul 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions