Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renaming instance-id and instance-name #589

Merged

Conversation

varad-ahirwadkar
Copy link
Contributor

Fixes: #555

Renaming instance-id and instance-name to workspace-id and workspace-name.

@ppc64le-cloud-bot ppc64le-cloud-bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Apr 15, 2024
Copy link
Member

@mkumatag mkumatag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Idea is not to rename, we should add the new fields and deprecate the old ones and remove later in the next release

@varad-ahirwadkar
Copy link
Contributor Author

Idea is not to rename, we should add the new fields and deprecate the old ones and remove later in the next release

Ok got it, thanks. I will do.

Copy link
Contributor

@Karthik-K-N Karthik-K-N left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of directly replacing instace-id with workspace-id , I think we should mark instance-id flag as deprecated and introduce workspace-id flag.

My concern is it will be breaking change better to remove later after warning user. But its upto you.

@varad-ahirwadkar varad-ahirwadkar force-pushed the rename_service_instance branch 4 times, most recently from 0d18710 to 446acb9 Compare May 22, 2024 14:59
@varad-ahirwadkar
Copy link
Contributor Author

@mkumatag @Karthik-K-N could you please review the changes? Thanks

cmd/create/create.go Outdated Show resolved Hide resolved
cmd/image/import/import.go Outdated Show resolved Hide resolved
@varad-ahirwadkar
Copy link
Contributor Author

I have also updated the InstanceName to COSInstanceName in cmd/image/upload/upload.go.

Copy link
Member

@mkumatag mkumatag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one small change, other LGTM

@@ -249,7 +249,7 @@ pvsadm image upload --bucket bucket1320 -f centos-8-latest.ova.gz --bucket-regio
func init() {
Cmd.Flags().StringVar(&pkg.ImageCMDOptions.ResourceGrp, "resource-group", "", "Name of user resource group.")
Cmd.Flags().StringVar(&pkg.ImageCMDOptions.ServicePlan, "cos-serviceplan", "standard", "Cloud Object Storage Class type, available values are [standard, lite].")
Cmd.Flags().StringVarP(&pkg.ImageCMDOptions.InstanceName, "cos-instance-name", "n", "", "Cloud Object Storage instance name.")
Cmd.Flags().StringVarP(&pkg.ImageCMDOptions.COSInstanceName, "cos-instance-name", "s", "", "Cloud Object Storage instance name.")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a breaking change, lets not rename the short flag to s here!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, will mark this shorthand flag as deprecated.

Cmd.Flags().MarkShorthandDeprecated("cos-instance-name", "please use --cos-instance-name")
Same flag has been used for import command with s shorthand -

Cmd.Flags().StringVarP(&pkg.ImageCMDOptions.COSInstanceName, "cos-instance-name", "s", "", "Cloud Object Storage instance name.")

Signed-off-by: Varad Ahirwadkar <varad.ahirwadkar1@ibm.com>
Copy link
Member

@mkumatag mkumatag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@ppc64le-cloud-bot ppc64le-cloud-bot added the lgtm Indicates that a PR is ready to be merged. label May 30, 2024
@ppc64le-cloud-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mkumatag, varad-ahirwadkar

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ppc64le-cloud-bot ppc64le-cloud-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 30, 2024
@ppc64le-cloud-bot ppc64le-cloud-bot merged commit 21ff2d6 into ppc64le-cloud:main May 30, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enhancement - PowerVS Service 'Instance' name/id should be renamed as 'Workspace'
4 participants