volume_attachments not present in server create/update notifications

Bug #1637639 reported by Steve McLellan on 2016-10-28
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Undecided
Unassigned

Bug Description

Following on from https://bugs.launchpad.net/nova/+bug/1637634, related to differences between the nova servers API response and compute.create/update notification payloads; also related to https://bugs.launchpad.net/nova/+bug/1637635

An example API response to retrieve a server's information is at http://paste.openstack.org/show/xbv2CwtHnhhl1nLLiJeN/

An example compute.create.end notification is at http://paste.openstack.org/show/zG5aJeUpC3LAGr0J0P2T/

An example compute.update.end notification is at http://paste.openstack.org/show/uwh1izVsaW5eg7zDrgFm/

'os-extended-volumes:volumes_attached' is missing from notification payloads. This is somewhat understandable since volumes are largely the concern of cinder, but the attachment information is related to nova. If it's undesirable to add this to notification payloads we'll need to make a decision in Searchlight whether to continue indexing this field on servers.

Steve McLellan (sjmc7) on 2016-10-28
tags: added: searchlight
Matt Riedemann (mriedem) wrote :

FWIW there is a notification when a volume is attached here:

https://github.com/openstack/nova/blob/03f8f5a08418080162a3d2f90658a597606e7c45/nova/compute/manager.py#L4689

And volume detach here:

https://github.com/openstack/nova/blob/03f8f5a08418080162a3d2f90658a597606e7c45/nova/compute/manager.py#L4829

But I guess the point of this bug is that the instance create and update notifications don't have BDM (attached volume) information in them.

Balazs Gibizer (balazs-gibizer) wrote :

For me the question is what data is needed for the searchlight project regarding the volume attachments? Do you need a list of BlockDeviceMapping objects [1] or just a list of attached volume ids or something else?

As a side note, adding the BDM information to the instance.update payloads means that we need an extra DB query to send the notification. In case of instance.create the bdm is available in the context of the notification sending.

[1] https://github.com/openstack/nova/blob/master/nova/objects/block_device.py#L67-L86

Changed in nova:
status: New → Incomplete
Steve McLellan (sjmc7) wrote :

The only information we currently get from the API response is the ID (and, weirdly, 'delete_on_termination'). It'd be neat to get more (particularly the volume name, size and device name) but as long as it's not present in the API response the ID alone is fine.

If it requires another database query that's considered too expensive/complicated we can treat volume attachments as a special case that we need to be aware of, but the aim of these tickets is to identify those fields and preferably reduce the number we have to deal with separately.

Launchpad Janitor (janitor) wrote :

[Expired for OpenStack Compute (nova) because there has been no activity for 60 days.]

Changed in nova:
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers