Revert the openstacksdk subclassing from shade. The idea was to
reduce the workload, but trying to make sure that the Cloud abstraction
in openstacksdk doesn't break shade's contract while we update things is
a ton of work to meet the contract that's not really valuable to people.
Instead, we'll put shade on lifesupport and only accept bugfix patches.
Revert "Make OpenStackCloud a subclass of Connection"
This reverts commit ab3f400064.
Revert "Use openstack.config directly for config"
This reverts commit 2b48637b67.
Revert "Remove the task manager"
This reverts commit 28e95889a0.
Change-Id: I3f5b5fb26af2f6c0bbaade24a04c3d1f274c8cce
This replaces the deprecated (in python 3.2) unittest.TestCase method
assertRaisesRegexp() with assertRaisesRegex().
Change-Id: I1f20db33e3acfc87c0e7a5c8cf45dc1b3121619e
Signed-off-by: Chuck Short <chucks@redhat.com>
The shade code lives in openstacksdk now and is a part of Connection.
Start making shade a subclass of that for backwards compat.
Mostly only deal with the constructor for now, but go ahead and do
list_flavors and get_flavor_by_id while we're looking at the extra
config override. Also remove list_projects because of its use of the
_normalize module.
keystoneauth lower-constraint needs to be bumped because of
status_code_retries.
Change-Id: Ibbe6e167d6285b30a9adbd0c5a89bc679c5645f3
For instance on call to cloud.node_set_provision_state(uuid, 'dummy')
the API currently only returns:
(400) Client Error for url: http://127.0.0.1:6385/v1/nodes/<UUID>\
/states/provision Bad Request
whereas the HTTP request also contains some more valuable information
in the body:
The requested action "dummy" can not be performed on node "<UUID>" \
while it is in state "enroll".
Change-Id: I8412a2fd4ba78ad4f43ac2f13b1404dd3c151ce5
Added retry logic mechanism and added them to the API calls
where ironic presently attempts to pull an exclusive
lock on the baremetal node.
Change-Id: Ia6fbc9eec612793b3214d7883e0552913a088d5d
After an epic battle with time, the python-ironicclient has been
driven from the land of shade, and there will be joy!
Change-Id: I234e2fc9d1800607c22eb447dd3e77428221695e
Update calls for numerous baremetal methods to utilize
the _baremetal_client calls instead of python-ironicclient.
Also corrected a minor baremetal port test and fixed the
base noauth test endpoint override as python-ironicclient
was previously injecting that for us.
Change-Id: I358a63a52067f7d48d71f0b23652491b2497fe43
Migrating tests to wrap up machine actions.
Ports will be migrated separately as there
will also need to be portgroups, which could
be wrapped into the same file/class depending
on how that ends up being implemented.
Change-Id: I239bbc134f42a47e8df75531dbd50916a97a6068
Migrating the machine tests where state transitions
occur, such as turning power on/off, maintenance mode,
hardware inspection, and general provision state changes
such as activating a node and deactivating a node.
Change-Id: I88663fecb79247d5473c47847f9c7405f447a80d
Migrated a number of simpler machine tests to using rest calls,
while removing the mocked client versions of the tests.
Added additional patch_machine tests, which raised the fact that
patch method was not normalizing the data being returned.
Added normalization since those fields are not normally returned
by get_machine.
Change-Id: I1c5f4ebd06fff40da45dbcc0d6ea0f7b108ce8fa
Shamelessly based upon pre-existing requests mock code in
shade, with the attempt to replace the existing baremetal
client mock testing.
This updates the way we're creating the ironic_client so that it
always does discovery, which _baremetal_client will always have
to do because of how the versioned discovery document is in ironic.
It also puts in a workaround for a bug that was found in keystoneauth's
new version discovery that we should eventually take out.
Change-Id: I0e811d69c3cba50f164cb2a3a1302b88fba51308