VMware: Fix initialization of datastore selector

The WSDL URL of storage policy service is determined and a session is
created using it in do_setup(). This session is later used to initialize
the datastore selector property (ds_sel), which uses the session for all
storage policy related API calls.

After commit a8fa3ceb1e72bac2ab67f569a2ca009f995f59fd (Integrate
OSprofiler and Cinder), the properties defined in vmdk module are called
before do_setup(). As a result, the ds_sel (datastore selector) property
is initialized with a session instance containing a 'None' PBM (storage
policy service) WSDL URL. This results in failures of all storage policy
related APIs invoked using datastore selector. This patch fixes the
problem by re-initializing the property in do_setup().

Change-Id: Ibdf8b23f9e215000cf9053b81d374066fabd6851
Closes-Bug: #1380675
ProphetStor driver consistency group support

Implement ProphetStor driver support for the new consistency group
feature in Cinder Kilo.

Change-Id: Id2f7a93cabcf4f54215a035b3ad8d30ea5439297
Implements: blueprint prophetstor-consistency-group
Remove outdated _ as a builting from pylintrc

Closes-bug: #1383302
Change-Id: I35e73fcabf39a01b667d570478227c960e1c450c
Merge "ProphetStor driver consistency group support"
Merge "VMware: Fix initialization of datastore selector"
Merge "Remove outdated _ as a builting from pylintrc"
Cinder api service doesn't handle SIGHUP properly

When SIGHUP signal is sent to cinder-api service, it doesn't complete
processing of all pending requests before terminating all the
processes.

This change is a copy of Abhishek Kekane's fix for nova api.

Change-Id: I049d2aa2f3ad1fe388e00213a71f374803ed409a
Closes-Bug: #1334647
Merge "Cinder api service doesn't handle SIGHUP properly"
Update volume-type's quota when extending volume

Now cinder only update total "gigabytes" quota but not update special
volume-type's "gigabytes" quota.

Fix bug #1375120

Change-Id: Ibb0b91afc81ba8c864f3c56fbe8a31972edd9bfc
Signed-off-by: Haomai Wang <haomai@unitedstack.com>
NFS Security Enhancements: allows secure NFS environment setup

This patch allows an OpenStack environment to run as a secure NAS
environment from the client and server perspective, including having
root squash enabled and not running file operations as the 'root'
user. This also sets Cinder file permissions as 660: removing
other/world file access.

The "nas_secure_file_permissions" option controls the setting of file
permissions when Cinder volumes are created. The option defaults to
"auto" to gracefully handle upgrade scenarios. When set to "auto",
a check is done during Cinder startup to determine if there are
existing Cinder volumes: no volumes will set the option to 'true',
and use secure file permissions. The detection of existing volumes will
set the option to 'false', and use the current insecure method of
handling file permissions.

The "nas_secure_file_operations" option controls whether file
operations are run as the 'root' user or the current OpenStack
'process' user. The option defaults to "auto" to gracefully handle
upgrade scenarios. When set to "auto", a check is done during Cinder
startup to determine if there are existing Cinder volumes: no volumes
will set the option to 'true', be secure and do NOT run as the 'root'
user. The detection of existing volumes will set the option to 'false',
and use the current method of running operations as the 'root' user.
For new installations, a 'marker file' is written so that subsequent
restarts of Cinder will know what the original determination had been.

This patch enables this functionality only for the NFS driver.
Other similar drivers can use this code to enable the same
functionality with the same config options.

DocImpact
Change-Id: I3d25f593beab7f5462576b14ab62d13d8c53e7c6
Implements: blueprint secure-nfs
Partial-Bug: 1260679
Imported Translations from Transifex

For more information about this automatic import see:
https://wiki.openstack.org/wiki/Translations/Infrastructure

Change-Id: I3fd4f684914909cd4fb35f7d0435a430c80ecfd6
Merge "NFS Security Enhancements: allows secure NFS environment setup"
Merge "Imported Translations from Transifex"
Move volume copy logic into manager

TODO: explanation is necessary

Related-Blueprint: generic-volume-migration
Change-Id: Ic3add11c272d3e262cc9a1a640660d947ea6f855
Introduce changes necessary for generic volume migration

This patch contains the core driver changes needed to make generic
volume migration possible.  By itself, no changes to the existing logic
for volume migration are introduced.  The intent is to keep the original
behaviour intact while allowing certain drivers that cannot attach
volumes locally to still participate in volume migration.

To allow this functionality, an 'is_attachable' function is added to the
volume driver definition.  This property indicates whether the volume
can be attached locally to the host and expose a path to the resulting
block device.  A driver author can override this and return False if
a driver cannot attach its volumes in a way that exposes a block device
path.  Doing so will cause the volume copy routine (copy_volume_data) to
use file I/O instead of calling out to `dd`.  The driver author is
expected to provide an implementation of open_volume() that returns
a file object capable of proxying I/O requests to the underlying storage
backend.

An RPC call for 'is_attachable' is added to allow querying of remote
volume capabilities.

The default volume open and close routines are currently unimplemented
and are the next step in this series.  The open routine will return
a file handle defined by the path to the block device.  This will allow
drivers like RBD which do not support attachment to migrate to and from
drivers which do support attachment, such as LVM.

Related-Blueprint: generic-volume-migration
Change-Id: I5876f755bc1ea972749fdcc02e1f186f7f2b207d
WIP

Change-Id: Ifcfccd96b869d22dd667c8e09ad2bc6586b30a32
WIP

Change-Id: I84a8022ce76e13c53022969cc77d5c6427e0566e
WIP

Change-Id: If2bbbedf73f28a48e8fcc8e6868fb531acf38589
WIP

Change-Id: I995d4a8dbc7ed887a6fff260b79e3880536f638f
WIP

Change-Id: I26681675456b722e50d54091cc4bb3eb41218114