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

Add networkID param to PVMInstance's DeleteNetwork() #400

Merged
merged 1 commit into from
Jun 10, 2024

Conversation

dharaneeshvrd
Copy link
Contributor

No description provided.

@ismirlia
Copy link
Collaborator

ismirlia commented May 30, 2024

So normally we can't change the existing definitions, but in this case it seems that in our code this is unused and from looking at the API, it's currently broken.

@yussufsh thoughts?

What is prompting this change @dharaneeshvrd ?

@dharaneeshvrd
Copy link
Contributor Author

@ismirlia I have tried using Mac address of the network that I wanted to remove, but getting below 405 error.

failed to delete the network to the pvminstanceid db194b86-6415-480a-8a78-fd3d0b6380f1: [DELETE /pcloud/v1/cloud-instances/{cloud_instance_id}/pvm-instances/{pvm_instance_id}/networks/{network_id}] pcloud.pvminstances.networks.delete (status 405): {}

Tried with this change and it went through, so submitted this fix.

@dharaneeshvrd
Copy link
Contributor Author

@ismirlia did you get a chance to look at my previous comment?

@dharaneeshvrd
Copy link
Contributor Author

@Prajyot-Parab @mkumatag Any input here?

Copy link
Contributor

@Prajyot-Parab Prajyot-Parab left a comment

Choose a reason for hiding this comment

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

/lgtm

@mkumatag
Copy link
Contributor

mkumatag commented Jun 5, 2024

@dharaneeshvrd are we trying this for first time?

@dharaneeshvrd
Copy link
Contributor Author

Yes I tried this for the first time and got this error, not sure it ever worked.
The API requires the networkID as required path param https://cloud.ibm.com/apidocs/power-cloud#pcloud-pvminstances-networks-delete.
Not sure how it got missed initially.

@mkumatag
Copy link
Contributor

mkumatag commented Jun 6, 2024

Yes I tried this for the first time and got this error, not sure it ever worked. The API requires the networkID as required path param https://cloud.ibm.com/apidocs/power-cloud#pcloud-pvminstances-networks-delete. Not sure how it got missed initially.

that's fair.. in that case @ismirlia can we merge this PR?

@dharaneeshvrd dharaneeshvrd changed the title Add networkID param to DeleteNetwork() Add networkID param to PVMInstance's DeleteNetwork() Jun 6, 2024
@ismirlia
Copy link
Collaborator

I think it's fine to merge. @yussufsh any thoughts?

Copy link
Collaborator

@yussufsh yussufsh left a comment

Choose a reason for hiding this comment

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

Network id seems required, as this is a fix for broken api we can merge this.
@ismirlia can you check why the body param with mac is needed? Is it an additional check for deleting the network?

@yussufsh yussufsh merged commit d835bd6 into IBM-Cloud:master Jun 10, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants