Commit Graph

6 Commits

Author SHA1 Message Date
Telles Nobrega f422b31b81 Fixing policies inconsistencies
Fixing some jobs/job-templates/job-executions policy inconsistencies.

Change-Id: I05223981bd44d5f467808576113c29fbb37a3191
Story: #2004675
Task: #28666
2019-03-06 13:50:28 -03:00
Telles Nobrega 7105a891c2 APIv2 - Fix 500 on malformed query string on
In order to improve return information to clients we are adding a check
to verify parameters before each call and return a more appropriate
message to the users.

Change-Id: I9923601d0903e415a3fe30bec9bdc8fc34b91ff6
Story: #2004506
Task: #28228
2019-01-09 15:52:22 -03:00
Jeremy Freudberg ccb9167e18 Various server-side fixes to APIv2
* Check if plugin_version key is in dict before doing something to it
* Fix references to non-existent policies
* Generally, correct how some responses get tweaked (in many cases the
  old way was throwing an error)
* Fix an incorrect schema

Change-Id: I6b4802a614e4b58678343f12856dd531827dc7b2
2018-01-25 05:23:22 +00:00
Shu Yingya 5fdba5c322 [APIv2] Update registry images tagging
The endpoint of image tag should be changed to follow guidelines
on tag[*]. Main ideas are:
1. To add, remove, or change tags, a PUT request should be sent to
   the root tags URL, the server responds with a 200 status code.
2. To delete the entire tag list associated with a resource, a
   DELETE request must be sent to the root tags URL.
3. the resource identified by URL must expose its tags with root
   URL like: http://example.com:8386/servers/1234567890/tags.
4. There also add a get tags method and a dozen of unit test

*: http://specs.openstack.org/openstack/api-wg/guidelines/tags.html

Partial-Implements: bp v2-api-experimental-impl
Change-Id: Ia70322538f966ad032ae804c99f6f07463461e7d
2017-01-23 10:24:31 +00:00
Michael McCune ef3815988e rename service api modules
This change renames the service api modules to be organized under the
sahara.service.api package. A v2 package has been added which holds the
equivalent v10 and v11 functions. To make the api version setup
transparent to the caller, the global OPS variable has been refactored
into the base sahara.service.api package.

Changes
* create sahara/service/api package
* rename sahara/service/api.py to sahara/service/api/v10.py
* rename sahara/service/edp/api.py to sahara/service/api/v11.py
* correct occurances of old imports in code and tests
* rename sahara/tests/unit/service/test_api.py to
  sahara/tests/unit/service/api/test_v10.py
* add initial v2 equivalents for current api services
* move global OPS object into the sahara.service.api package
* add documentation for the api service layer

Partial-Implements: bp v2-api-experimental-impl
Depends-On: I16918a30a862b42edd7a982caf555be618199ac3
Change-Id: Iefbedbc76ac620ff012bcaf536c17637b6252a15
2016-03-28 19:21:19 -04:00
Michael McCune a9137addb4 add initial v2 api
this change implements the initial v2 experimental api. it is
implemented as an optional series of class that can be configured
through the paste deploy configuration file.

* add wsgi auth validator
* add middleware router
* add v2 endpoints
* add v2 flask blueprint object
* add optional paste filter and composite
* add developer docs for v2 api

Change-Id: I74627c0879851b354b5043f8a6ff91bae8438bb1
Partial-Implements: bp v2-api-experimental-impl
2016-02-10 09:56:07 -05:00