cinder/cinder/tests/unit/backup
Gorka Eguileor af0f00bc52 Run backup compression on native thread
Backup data compression is a CPU bound operation that will not yield to
other greenthreads, so given enough simultaneous backup operations they
will lead to other threads' starvation.

This is really problematic for DB connections, since starvation will
lead to connections getting dropped with errors such as "Lost connection
to MySQL server during query".

Detailed information on why these connections get dropped can be found
in comment "[31 Aug 2007 9:21] Magnus Blåudd" on this MySQL bug [1].

These DB issues may result in backups unnecessary ending in an "error"
state.

This patch fixes this by moving the compression to a native thread so
the cooperative multitasking in Cinder Backup can continue switching
threads.

[1] https://bugs.mysql.com/bug.php?id=28359

Closes-Bug: #1692775
Closes-Bug: #1719580
Change-Id: I1946dc0ad9cb7a68072a39816fa9fa224c2eb6a5
2017-10-16 17:09:46 +02:00
..
drivers Run backup compression on native thread 2017-10-16 17:09:46 +02:00
__init__.py Move unit tests into dedicated directory 2015-04-21 18:40:40 -06:00
fake_backup.py Move all backups related unit tests to backup directory 2016-05-26 17:09:33 +03:00
fake_google_client.py Use googleapiclient import instead of apiclient 2016-03-11 12:19:01 +01:00
fake_google_client2.py Add cinder backup driver for Google Cloud Storage 2016-01-18 23:28:23 +05:30
fake_service.py Rename method 'delete' to 'delete_backup' in backup drivers 2017-07-04 13:35:03 +03:00
fake_service_with_verify.py Remove oslo logging from backup unit tests 2015-06-27 21:23:34 +00:00
fake_swift_client.py Remove oslo logging from backup unit tests 2015-06-27 21:23:34 +00:00
fake_swift_client2.py Switch to the oslo_utils.fileutils 2015-08-20 07:47:48 +00:00
test_backup.py Add ability to specify backup driver via class name 2017-10-11 12:59:00 +03:00
test_rpcapi.py Add service dynamic log change/query 2017-05-16 13:37:35 +02:00