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

[GOCA] migrate xml package from xmlpath to encoding/xml #2830

Closed
7 tasks
treywelsh opened this issue Jan 18, 2019 · 1 comment
Closed
7 tasks

[GOCA] migrate xml package from xmlpath to encoding/xml #2830

treywelsh opened this issue Jan 18, 2019 · 1 comment

Comments

@treywelsh
Copy link
Contributor

treywelsh commented Jan 18, 2019

Description
The goal of this migration is to use the encoding/xml package instead of xmlpath in order to decode the XML content from OpenNebula.
For each OpenNebula entity, a set of structures will be defined to which is directly mapped the XML content.
The developper will work directly with theses structures.
Sometimes due to dynamic parts he will have to do some tests but less than with xmlpath module.

The types conversions and parsing part are removed from the developper code,
in this way, his code will be much more simple, and this also allow auto completion.

Use case
It's useful for every XXX.info requests.

Interface Changes
This does not modify functions prototypes, but add a bunch on structures that the developer can use directly.

Additional Context
I'll provide a pull request soon.

Progress Status

  • Branch created
  • Code committed to development branch
  • Testing - QA
  • Documentation
  • Release notes - resolved issues, compatibility, known issues
  • Code committed to upstream release/hotfix branches
  • Documentation committed to upstream release/hotfix branches
christian7007 pushed a commit that referenced this issue Feb 6, 2019
Shared structs: snapshot, quotas, permissions, lock
christian7007 pushed a commit that referenced this issue Feb 6, 2019
…endpoint. It's used by the XML-RPC method rafstatus
christian7007 pushed a commit that referenced this issue Feb 6, 2019
christian7007 pushed a commit that referenced this issue Feb 6, 2019
@treywelsh treywelsh reopened this Feb 21, 2019
@treywelsh
Copy link
Contributor Author

Some bug has been found by the ONE team in my code so I reopen this case and provide a pull request to fix this.

Add:

  • Info method struct cleaning
  • remove some mutualized part among structs, it cost a bit more of memory but the code is less tricky...

tinova pushed a commit that referenced this issue Feb 21, 2019
* F #2830: GOCA - fix: clean structs in Info call to prevent keeping old data

* F #2830: GOCA - fix: remove struct shared parts as it imply more code complexity than needed
rsmontero added a commit that referenced this issue Apr 1, 2019
rsmontero pushed a commit that referenced this issue Apr 1, 2019
rsmontero added a commit that referenced this issue Apr 1, 2019
(cherry picked from commit eecb5bd)
christian7007 pushed a commit to christian7007/one that referenced this issue Apr 1, 2019
rsmontero pushed a commit that referenced this issue Apr 1, 2019
tinova pushed a commit that referenced this issue Jul 11, 2019
 modify the way to access to the resources (Warning: breaking change)


* F #2940: GOCA - add controller

 - API refactored
 - Client externalized
 - Migrate entities and related tests.

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - remove EndpointCall method

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2772: GOCA - Add http config and update dep

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - add examples

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - replace lock methods by values

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - remove snake case

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #3209: GOCA - add vm group mapping

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2830: GOCA - rename xmlresource file

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - change update parameter type

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - permission as parameter of chmod

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2930: GOCA - split vm file

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #3209: GOCA - Add ACL parameters constants

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - fix id are signed integers

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2830: GOCA - export and improve consistency

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2940: GOCA - apply Go mixed cap case

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #3455: GOCA - split in packages

 - shorten and export struct names

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>

* F #2830: GOCA - fix ACL and Zone regressions

Signed-off-by: Pierre Lafievre <pierre.lafievre@iguanesolutions.com>
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

No branches or pull requests

1 participant