-
Notifications
You must be signed in to change notification settings - Fork 22
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
fix vrealize:push fails for vCD 10.5, API version 38.0 #183
Conversation
*/ | ||
private static final String URL_SESSION = "/api/sessions"; | ||
private static final String PROVIDER_URL_SESSION = "/cloudapi/1.0.0/sessions/provider"; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd suggest to make both the REST endpoint backward compatible with old API version, for example check the vCD API version and if it is >= 38.0 then use the PROVIDER_URL_SESSION otherwise to use URL_SESSION
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your feedback.
According to the API documentation is available since API v33 - https://developer.vmware.com/apis/vmware-cloud-director/latest/cloudapi/1.0.0/sessions/provider/post/
From these docs we can see v33 is mapped to VCD 10, which is deprecated -> https://developer.vmware.com/docs/14143/vmware-cloud-director-api-programming-guide/
Should we support deprecated versions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think @akantchev 's idea is to have support for backwards compatibility in case the user is running on an older vCD version which supports just the old api
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see the second link isn't working properly - I am attaching another one - https://docs.vmware.com/en/VMware-Cloud-Director/index.html
VCD API version <=34 is deprecated and not supported, and this change supports =>33
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changing should be fine. The old endpoint will be for very old VCD versions that are out of support for more than an year (10.1 (v34) EOL is 2022-04-09)
Hi, @vganevjb . I see you updated CHANGELOG.md which is great. Could you updated Release.md as well? |
7c3485f
to
9976783
Compare
*/ | ||
private static final String URL_SESSION = "/api/sessions"; | ||
private static final String PROVIDER_URL_SESSION = "/cloudapi/1.0.0/sessions/provider"; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changing should be fine. The old endpoint will be for very old VCD versions that are out of support for more than an year (10.1 (v34) EOL is 2022-04-09)
@VenelinBakalov I'd say let's merge this |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
@Michaelpalacce I've missed the notification for this..it seems now there are some merge conflicts |
9976783
to
3068e8b
Compare
Signed-off-by: Vladislav Ganev <gvladislav@vmware.com>
3068e8b
to
596f285
Compare
Description
VMware Cloud Director 10.5 and later do not support the /api/sessions API login endpoint.
The /api/sessions API login endpoint is deprecated since VMware Cloud Director API version 33.0. For version 38.0 and later, the /api/sessions API login endpoint is no longer supported. You can use the VMware Cloud Director OpenAPI login endpoints to access VMware Cloud Director.
Service provider access to the system organization- POST cloudapi/1.0.0/sessions/provider
Tenant access to all other organizations apart from the system organization- POST cloudapi/1.0.0/sessions
As per the backward compatibility commitment of VMware Cloud Director, versions 37.2 and earlier continue to support the /api/sessions API login endpoint.
Checklist
Fixed #XXX -
orClosed #XXX -
prefix to auto-close the issueTesting
Release Notes
Related issues and PRs
Fixed #166