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

SDK fixes including CP-53003 #6210

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

kc284
Copy link
Contributor

@kc284 kc284 commented Jan 6, 2025

Commits best reviewed separately.

  • CP-53003: Use JsonRpc v1.0 by default and switch to v2.0 once the API version is known.
  • Removal of deprecated methods and unused internal methods.
  • Refactoring to fix some inefficiencies when loading and saving certificates in PS.

kc284 added 3 commits January 6, 2025 12:43
Signed-off-by: Konstantina Chremmou <[email protected]>
- Moved certificate methods to the Connect-XenServer cmdlet and refactored them to avoid multiple loads of the global variable KnownServerCertificatesFilePath.
- Fixed accessibility of CommonCmdletFunctions members.

Signed-off-by: Konstantina Chremmou <[email protected]>
… version is known.

Signed-off-by: Konstantina Chremmou <[email protected]>
/// Return a positive number if the given session's API version is greater than the given
/// API_version, negative if it is less, and 0 if they are equal.
/// </summary>
internal static int APIVersionCompare(Session session, API_Version v)
Copy link
Contributor

Choose a reason for hiding this comment

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

why remove those functions?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

These methods are not visible outside the library because they are internal. Inside the library they are not used, which means they are not needed.
Now, if someone has implemented the SDK in the way XenCenter has, the methods might be in use, however, XC's design is not ideal and should not be encouraged because it leads to complicated code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants