volume_image_metadata missing from volume list

The volume_image_metadata field was missing from the volume list
because we tried to filter VolumeGlanceMetadata against a non-existent
project_id field. Filtering should be done on the Volume associated
to the VolumeGlanceMetadata instead.

Move project_id filtering out of model_query as it assumes
the project_id field is in the queried model itself.
Build the filter ourselves against Volume.

Fix glance metadata SQL query performance

The query built to retrieve glance metadata associated to a volume
was sub-optimal: all rows of volume_glance_metadata were returned.

Fix it by properly joining the 2 tables with volume_id field.

Closes-bug: #1337526
Closes-bug: #1349936
Change-Id: I6053708296f2b5e24513dc87ed63da0f67c220ae
(cherry picked from commit 06dd7f28d1d3ec8619df0d25ddfe977d538897b3)
(cherry picked from commit 8f8a8a6ffe14cf7bb461dc26d178bf8acc8ddf12)
Merge "volume_image_metadata missing from volume list" into stable/icehouse