Commit Graph

26 Commits

Author SHA1 Message Date
Mark Doffman 7f82c5e681 Aggregate create and destroy work against API db
Make aggregate.create() and destroy() use the API rather than cell database.
Also block aggregate creation until main database empty. This makes
Aggregate.create() fail until the main database has had all of its aggreagtes
migrated. Since we want to avoid any overlap or clashes in integer ids we
need to enforce this.

Note that this includes a change to a notification sample, which encodes
the function and module of a sample exception (which happens to be during
an aggregate operation). Since the notifications are encoding internal
function names, which can and will change over time, this is an expected
change.

blueprint cells-aggregate-api-db

Co-Authored-By: Dan Smith <dansmith@redhat.com>
Change-Id: Ida70e3c05f93d6044ddef4fcbc1af999ac1b1944
2016-08-01 08:22:08 -07:00
Jenkins eec3a2b9e8 Merge "Bump service version for BuildRequest deletion" 2016-07-21 00:44:34 +00:00
Zhihai Song bd0ba826e4 Transform instance.restore notifications
The instance.restore.start and instance.restore.end notifications
are transformed to the versioned framework.

Change-Id: I4459ec05a7153af7a0f04adcccb9d99cb5f661e5
Implements: bp versioned-notification-transformation-newton
2016-07-12 20:57:07 -04:00
Andrew Laski 916f01ef7d Bump service version for BuildRequest deletion
This service version indicates that the successful delete of a
BuildRequest during instance deletion will cause nova-conductor to stop
a build when it notices that the BuildRequest is gone. This simplifies
the delete code for dealing with pre-scheduled instances.

Change-Id: I961d002cccd3e01a26cb5174e0804db7fc1f836d
2016-07-12 13:35:36 -04:00
Jenkins 9f2597fac6 Merge "Transform instance.resize notifications" 2016-07-11 02:17:47 +00:00
Jenkins 1a074a7284 Merge "Transform instance.pause notifications" 2016-07-11 02:15:59 +00:00
Anusha Unnam 029f92d93a Transform instance.resize notifications
The instance.resize.start and instance.resize.end notifications
are transformed to the versioned framework.

Implements: bp versioned-notification-transformation-newton
Change-Id: If5183eddb7d79712f360cde11c554e4798f86255
2016-07-08 16:52:15 +01:00
Balazs Gibizer 9fafcc7883 Replace DOS line ending with UNIX
Some of the notification sample files had DOS line endings.

Change-Id: If1a120fc782a144966d41e0c3b2e0859bbffcb44
2016-07-08 09:21:15 +02:00
Sujitha 5bd8e2d47c Transform instance.pause notifications
The instance.pause.start and instance.pause.end notifications
are transformed to the versioned framework.

Implements: bp versioned-notification-transformation-newton

Change-Id: I67979c1cd7cd221a2241846255bf2a884a9d60f5
2016-07-07 15:26:53 +00:00
Béla Vancsics 1d0326cce1 Transform instance.shelve notifications
Instance.shelve.start and instance.shelve.end notifications
are transformed to the new versioned framework.

Change-Id: Ibb52f4c9d8ec10810916a6ccb2bb494db7300d05
Implements: bp versioned-notification-transformation-newton
2016-07-07 09:44:11 +02:00
Pushkar Umaranikar db064bbb40 Transform instance.suspend notifications
The instance.suspend.start and instance.suspend.end
notifications are transformed to the versioned notifications
framework.

Change-Id: I6a90019773c415db9d27c893eb64466ae101b7d7
Implements: blueprint versioned-notification-transformation-newton
Depends-On: #313654
2016-07-01 19:04:04 +00:00
Zhihai Song 2a99eb1f3a Transform instance.power_on notifications
The instance.power_on.start and instance.power_on.end notifications
are transformed to the versioned framework.

Change-Id: I4e4fd701a59064b89e38b50dcc01c9d8846a09b0
Implements: bp versioned-notification-transformation-newton
2016-07-01 15:36:41 +00:00
Balazs Gibizer 87e13112b1 Transform instance.update notification
Change-Id: I4e1ca357322bdbcb95e4803001f4a7dc1bd37f04
Implements: bp versioned-notification-transformation-newton
2016-06-30 16:54:57 +02:00
Balazs Gibizer 998235da63 Transform instance.delete notifications
The instance.delete.start and instance.delete.end notifications
are transformed to the versioned framework using the generic
InstanceActionNotification and InstanceActionPayload class.

There is no instance.delete.error notification in legacy so
it is not added here but considered as a future improvement.

Change-Id: Iddbe50ce0ad3c14562df800bbc09ec5a7e840485
Implements: bp versioned-notification-transformation-newton
2016-06-30 16:54:51 +02:00
Artom Lifshitz e2eb6659a4 Compute manager device tagging support
This patch allows the network manager(s) to set virtual device tags if
they are present during allocation.

Implements: blueprint virt-device-role-tagging
Co-authored-by: Vladik Romanovsky <vromanso@redhat.com>
Co-authored-by: Dan Smith <dansmith@redhat.com>
Change-Id: I8367f740d6d4ebaeb81bc74c6a82a8faf5cd8308
2016-06-29 16:53:34 -07:00
Andrew Laski aeebd6614a Update get_instance_diagnostics for instance objects
Removes a longstanding TODO to update this method to handle instance
objects. The method is not actually used anywhere so there are no
upgrade concerns, but proper protocol is observed regardless.

Change-Id: Ieaf538fa2dc5c4a15574cc6aacac26abbac3b5a2
2016-06-28 10:36:25 -04:00
Matt Riedemann df0a4e0990 Bump the service version for get-me-a-network support
The REST API is going to be checking that all computes
in the deployment are running new enough code to support
network requests with the special 'auto' and 'none' values
for Get Me a Network, so we need to bump the service version
which can be used as the minimum version to check.

Part of blueprint get-me-a-network

Change-Id: Ia1af75422d5e1fd4535c1ed9703d855239282559
2016-06-24 14:02:24 -04:00
Laszlo Hegedus 6329d721ef Transform wrap_exception notification to versioned format
A new versioned notification is emitted from the wrap_exception
decorator.

Change-Id: I8fcbce111537dae6ad3ba0961fb761540ae800ed
Partially-Implements: bp versioned-notification-transformation-newton
2016-06-21 09:39:47 +02:00
Timofey Durakov 86a8006202 force_live_migration remove redundant check
During force_live_migration operation there are 2
checks of migration status, one on api layer and one on
compute side, second one requires rpc request to be done
and also to query the db. This check could be removed as additional
one doesn't guarantee that live_migration is not already completed,
also is very small window between api and compute side.
Target compute host is now taken from migration object rather
then instance.host field, which allows to guarantee that nova will not
pause already migrated instance.

Change-Id: I51585302e898251e26cbf311aeac38a0ec329001
2016-05-11 16:54:27 +03:00
Dan Smith f9b62dffe0 Migrate compute node resource information to Inventory objects
This does a live migration of compute node resource information from the
current location (in compute_nodes columns) to the new desired location
of records in the inventories table. It only does this if all control
services have been upgraded to a level that understands this.

Related to blueprint compute-node-inventory-newton

Change-Id: Ieda099d3f617713f09315b2b1e932a7c1d6f45c4
2016-04-11 07:43:04 -07:00
Sean Dague 235e0b04ea Revert "functional: Grab the service version from the module"
This reverts commit d411d60587.

The point of doc/*samples* is they are static files, not
dynamic. We shouldn't be doing substitution here, this
breaks all kinds of things, including the doc target.

Change-Id: Iaaf9fa0096ab62e6d3efbe018d8d4853a2ff8cda
Closes-Bug: #1553634
2016-03-07 12:48:40 -05:00
Nikola Dipanov d411d60587 functional: Grab the service version from the module
This way we avoid having to change the test template every time we bump
the version, it will be taken from the module.

Change-Id: I699b737e0e234f0649f6d207a648c60d74d9701e
2016-02-29 09:36:31 +00:00
Andrea Rosa fa00292546 Abort an ongoing live migration
This change adds a DELETE call on the server-migrations object to cancel
a running live migration of a specific instance.
TO perform the cancellation the virtualization driver needs to support
it, in case that the feature is not supported we return an error.
We allow a cancellation of a migration only if the migration is
running at the moment of the request and if the migration type is equal
to 'live-migration'.
In this change we implement this feature for the libvirt driver.
When the cancellation of a live migration succeeded we rollback the live
migration and we set the state of the Migration object equals to
'cancelled'.
The implementation of this change is based on the work done by the
implementation of the feature called 'force live migration':
https://review.openstack.org/245921

DocImpact
ApiImpact

Implements blueprint: abort-live-migration
Change-Id: I1ff861e54997a069894b542bd764ac3ef1b3dbb2
2016-02-26 15:11:41 +00:00
Pawel Koniszewski c9091d0871 Add new API to force live migration to complete
This change adds manual knob to force ongoing live migration to
complete. It is implemented as a new server-migrations API.

DocImpact
ApiImpact

Implements: blueprint pause-vm-during-live-migration
Change-Id: I034b4041414a797f65ede52db2963107f2ef7456
2016-02-08 08:59:52 +01:00
Dan Smith 2d7a851199 Allow sending the migrate data objects over the wire
This makes us actually capable of sending migrate_data objects
over the wire and handles all the compatibility work to tolerate
older nodes without this support.

Note this also fixes a bug in the libvirt migration data
object where the serial console field should be nullable
(per existing code) but wasn't. Since this is the patch that
actually lets this object be sent over the wire, we can update
the definition and the hash without needing a version bump.

Related to blueprint objectify-live-migrate-data

Change-Id: I8ad7a91910e269c27bc74389a9d4d2c7388313d6
2016-01-29 04:04:06 -08:00
Balazs Gibizer 1c4414a264 Adds json sample for the versioned notifications
This patch adds infrastructure to store and verify json samples
about versioned notifications. Also it adds sample for the service.update
notification as that is the only existing versioned notification.

A new notification_sample_tests subtree added to the functional test
tree to verify that the emitted notifications match with the stored sample.

Partially-Implements: bp versioned-notification-api
Change-Id: I3a70b7b5d6d427611a9d2c1610e0d55aff88f0e8
2016-01-28 15:31:21 +01:00