Change parameters of add_timestamp in ComputeDriverCPUMonitor class

Change parameter 'cls' to 'self' in wrapper. 'cls' may mislead developpers
that this decorator returns a classmethod. Use functools.wraps to follow
the common pattern of decorator in nova.

closes-bug: #1288281

Change-Id: I6acbcba7297607dc6d07e8668ad07e6ca81d4456
Add lock on API layer delete floating IP

There are potential race condition when multiple nova-api
service is running. We need to prevent the concurrent access to
the same floating ip, though db layer function is ok for floating
ip, the quota will be released more than one time and it will
lead to potential problem later

So the solution: check whether the db is *really* updated with the
value we want, which means the second operation will fail and
return None, so network api layer can handle it

Change-Id: I028938a4c387d21a8880ae168b161a763e7361ff
Closes-Bug: #1268569
libvirt: Handle `listDevices` unsupported exception

It's possible that `listDevices` will return an exception if it's not
currently supported.

If this happens, the compute service will fail to start up.

The proposed solution is to catch this error, log a warning, and allow
the compute-service to continue initialization.

Change-Id: If152abd1080e9ba395de5d8ea10f5e0c476d4e2b
Closes-Bug: #1304721
Fix security group list when not defined for an instance

If an instance has an empty security group list an exception
is thrown due to iteration attempt of None.

To fix this, this patch modifies get_instance_security_group
to return an empty list instead of None.

Change-Id: I7efb3c3a58d7e20501d126c6d194479ca1d14166
Closes-Bug: #1291489
Fix the explanation of HTTPNotFound for cell showing v2 API

This patch adds the explanation to cell showing in v2 API, when
the cell is not found, the exception of HTTPNotFound will return
more infomation.

Change-Id: I25dee08a04ad974af5309999527e0f173d2c2cab
Closes-Bug: #1316152
Fixes arguments parsing when executing command

A regression was caused by changing the eventlet.subprocess.Popen
with the builtin subprocess.Popen (by using the nova.utils execute
method) without changing the way the arguments were parsed.

In the v1 volume utilities module, the execution args were parsed
separated by whitespaces, which is not allowed by the builtin
subprocess.Popen, causing a "not found" error.

This error is returned for example when attaching a volume, at the
point where iscsicli tool is used to login the iSCSI target or portal.

This patch fixes the issue by simply splitting the args.

Closes-bug: #1317180

Change-Id: Iee7d5de0dde8b68d8f2bab4214e9b6779ad9f722
Fix wrong method name for test_hacking

There were two methods with same name, let's fix it.

Change-Id: I114ff187e1128dd042ee836ac7b24fb5bcb9c265
Downgrade and fix log message for floating ip already disassociated

When a floating IP is associated, try to disassociate may
get an FloatingIpNotAssociated exception. This patch
fixes the log message and downgrades the log
level as it is something that will reasonably occur.

Change-Id: I1d4d5fe916d99024ff4df53d300a0f26d74eb102
Merge "Change parameters of add_timestamp in ComputeDriverCPUMonitor class"
Merge "Fix wrong method name for test_hacking"
Merge "Fix security group list when not defined for an instance"
Merge "Add lock on API layer delete floating IP"
Imported Translations from Transifex

Change-Id: I4164c96c95ac150e18e4ea2b0ebbfdf6ec35e76c
Fix the duplicated extension summaries

If operating `nova --os-compute-api-version 3 extension-list`, the
summaries of both flavor-extra-specs and flavors extensions are the
same "Flavors Extension.". The summary of flavor-extra-specs should
include its feature.
There is a same issue on os-extended-server-attributes and
os-extended-availability-zone extensions also.

This patch fixes these summaries.

Change-Id: I6778229221ca80632b3a303745ff5133488f327d
Related-Bug: #1318973
Merge "libvirt: Handle `listDevices` unsupported exception"
Merge "Fixes arguments parsing when executing command"
Partially remove quota-class logic from nova.quotas and test_quotas

Continuation of quota-class removal started in
I1110022d6f628d03aaf363da707f2d2ef1600437.

* No need to have quota-class in FakeContext since quota-class isn't in
  the real context anymore.
* Don't check for quota_class _DEFAULT_QUOTA_NAME='default' in
  get_defaults
* Remove get_by_class
* Remove get_class_quotas
* Full removal is in the subsequent patch.

Change-Id: Ia563ac3341b980c1b5a4a45fe73770ddc27acc91
Merge "Fix the duplicated extension summaries"
Merge "Fix the explanation of HTTPNotFound for cell showing v2 API"
Merge "Downgrade and fix log message for floating ip already disassociated"