* Update karbor from branch 'master'
- Merge "Switch legacy Zuul jobs to native Zuul v3 jobs"
- Switch legacy Zuul jobs to native Zuul v3 jobs
Replace the 'karbor-dsvm-fullstack' legacy Zuul job with
the 'karbor-fullstack' native Zuul v3 job.
See
https://governance.openstack.org/tc/goals/selected/victoria/native-zuulv3-jobs.html
for more details.
Change-Id: I558c8e02011e98950354266254511bd113d5c5ec
* Update karbor from branch 'master'
- Merge "Fix 'filter' object has no len ()"
- Fix 'filter' object has no len ()
Karbor has a python3 compatibility issue where it will fail with:
TypeError: object of type 'filter' has no len(). 'filter' is a list
in python.
Change-Id: I6505e454e2073c1611cbe5c4887241253051b1f1
Closes-Bug: #1891732
* Update karbor from branch 'master'
- Merge "Fix inner has no attribute 'message'"
- Fix inner has no attribute 'message'
When DBDeadlock in karbor-api service, it get the following error:
AttributeError: 'DBDeadlock' object has no attribute 'message'.
This patch corrects that problem.
Change-Id: I1b268f5cca2c4efdcfb055d2fd8dfe522e6daf9d
Closes-Bug: #1891571
* Update karbor from branch 'master'
- Use unittest.mock instead of third party mock
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.
Change-Id: Ifd0d1b8aa419e39361e76a4f846cb4eeaf0d46ca
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* Update karbor from branch 'master'
- Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0.1 which
supports Python 3.
Fix problems found.
Remove hacking and friends from lower-constraints, they are not needed
for installation.
Change-Id: I6691687f0cd2fe4c9e7f2a76d333ca9eacb0cbf3
* Update karbor from branch 'master'
- Cleanup py27 support
This repo is now testing only with Python 3, so let's make
a few cleanups:
- Remove python 2.7 stanza from setup.py
- Add requires on python >= 3.6 to setup.cfg so that pypi and pip
know about the requirement
- Remove obsolete sections from setup.cfg
- Update classifiers
- Switch to using sphinx-build
- Cleanup doc/source/conf.py to remove now obsolete content.
- Use newer openstackdocstheme version
- Move constraints into deps
- Increase warlock dependency, glanceclient blocks version 1.3.0
Change-Id: I8feb2e86281f2250bdc379b7868c5e738c1a19e6
* Update karbor from branch 'master'
- Merge "Add unit tests for trigger update API"
- Add unit tests for trigger update API
Change-Id: I7f74c0346eef45ac83207410756e003266989bba
* Update karbor from branch 'master'
- Merge "Remove password display for rabbitmq on connection log"
- Remove password display for rabbitmq on connection log
When start karbor-protection and karbor-operationengine service,
Karbor will log rabbitmq password if debug is enabled. In a
production environment, this is pretty bad. This patch will fix it.
Change-Id: I11bd6db001739869fc6cddd005c9990d2943b809
Closes-Bug: #1859540
* Update karbor from branch 'master'
- Merge "Preserve request id in Karbor logs"
- Preserve request id in Karbor logs
When the admin context is retrieved the user context and its request
ID is lost and all subsequent log entries have different request IDs.
The fix is to pass the overwrite parameter in Karbor's RequestContext
__init__ method to the parent oslo class.
Change-Id: I1091ddc8a36244132883932a3a21dea5274eb34a
Closes-Bug: #1859433
* Update karbor from branch 'master'
- Remove unsupported calls
Because kubernetes 11.0.0 deleted the function of
'kubernetes.client.api_client.ApiClient.__del__',
which caused an ut error and deleted the relevant mock call.
Change-Id: I1ecade75227b3dc37c8fcdf775b7823583faea43
* Update karbor from branch 'master'
- Fix unit test error
Fix all the order of decorators and parameters in unittest.
Change-Id: Ic055aaf38f1e99d21ca1ada3055048ee72a360d9
* Update karbor from branch 'master'
- Merge "Fix get min interval error"
- Fix get min interval error
When we use get_min_interval method, the exit condition is
the execution time is bigger than the rate time. But default
minutes rate is 2, this may leads errors when the interval
is bigger than 2 minutes, it always return None. So we can
not use min interval to judge if the interval is smaller than
that we configured in the configuration file. This should be
fixed.
Story: 2006848
Task: 37436
Change-Id: I268051f05f9b89e1b6013cfc8cecf90e9dc78581
* Update karbor from branch 'master'
- Merge "Use trustee project_name instead of fixed value"
- Use trustee project_name instead of fixed value
Currently, when the default project name for openstack
services is not "service", it will fail when listing
protectable resources. This patch using trustee.project_name
to replace it.
Story: 2006797
Task: 37343
Change-Id: I8be62bb00e70dacd174e7fa3bd65489fb63488ab
* Update karbor from branch 'master'
- Merge "Add unit test for services api"
- Add unit test for services api
Change-Id: I0a4cec43c76d64191c5e962674ba31b5d6a834a3
Signed-off-by: helei <helei@cmss.chinamobile.com>
* Update karbor from branch 'master'
- Merge "Fix bug for running unittest with unittest module"
- Fix bug for running unittest with unittest module
When we run unittest with a way like:
python -m unittest2 <test_file>
then NoSuchOptError exception will raised
Change-Id: Ib0f9276c1b86ff7f2d1e401ddfae2bf4e920fa78
* Update karbor from branch 'master'
- Fix unit test error
Fix the order of decorators and parameters for
karbor.protection.manager.ProtectionServiceTest in unittest.
Change-Id: I9d58c33787e0b2039a046ea30c7238485a76af2d
* Update karbor from branch 'master'
- Modify the time interval configurations in devstack
Story: 2006848
Task: 37436
Change-Id: I9ae08550f74347fc8f8436eca3cf4320ec97dd1f
* Update karbor from branch 'master'
- Remove invalid exception catching
List operation of verifications will never raise VerificationNotFound
exception in _get_all method, we should remove it to normalize the
error code.
Change-Id: Ia1a6345b1e38b9ccc4246d2d39d11cc8e537cb4e
* Update karbor from branch 'master'
- Merge "Add some operation log"
- Add some operation log
For protect operation and retention operation, lacks some
key operation log print, so we add it.
Change-Id: Ife73b29511de3eea5094732fcfc82ff5e9783bc2
Signed-off-by: guolei <guolei@cmss.chinamobile.com>
* Update karbor from branch 'master'
- Merge "Imported Translations from Zanata"
- Imported Translations from Zanata
For more information about this automatic import see:
https://docs.openstack.org/i18n/latest/reviewing-translation-import.html
Change-Id: I63ef76eaa7bc22c62bc99bd0fcc9a3e2adec0f51
* Update karbor from branch 'master'
- Merge "Add unit test for quota api"
- Add unit test for quota api
Change-Id: I5f4bbeced540df4fa002b273728833d98958ebc2
* Update karbor from branch 'master'
- Merge "Remove invalid none value judgment"
- Remove invalid none value judgment
volume will never be none here, so we can remove the none
value judgment and improve the code execution efficiency.
Change-Id: I5d35eebda6d4e9d8fd31a2e32cbcc68632afb2c8
* Update karbor from branch 'master'
- Merge "Add trgger start and end time value check"
- Add trgger start and end time value check
Currently, karbor do not check start time and end
time value, so the end time may be early than start
time. This patch will fix it.
Story: 2006402
Task: 36284
Change-Id: If8909c9abd6fdcd7ce2e85a61472a8dc43f6fe51
* Update karbor from branch 'master'
- Merge "Do not use 'self' in classmethod"
- Do not use 'self' in classmethod
'cls' should be used in classmethd, instead of 'self'.
This patch corrects this in the following places:
- karbor/services/protection/checkpoint.py
- karbor/services/protection/protection_plugins/network/neutron_protection_plugin.py
Change-Id: I70c5ae7d3ea79ef5868a222509e583d510d8607c
* Update karbor from branch 'master'
- Merge "Update master for stable/train"
- Update master for stable/train
Add file to the reno documentation build to show release notes for
stable/train.
Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/train.
Change-Id: I8a13402cc47bc33a38182b3340987eefd9026850
Sem-Ver: feature
* Update karbor from branch 'master'
- Merge "Replace use of log.warn with log.warning"
- Replace use of log.warn with log.warning
LOG.warn is deprecated in Python3 and was used only here
in karbor, this patch updates it to LOG.warning.
Change-Id: Icad346bb6fd3efcac2f42fead1327585297f2f96
* Update karbor from branch 'master'
- Merge "Remove the code which is unreachable"
- Remove the code which is unreachable
Currently, in neutron_protection_plugin, some code is
unreachable and will never be executed. This patch will
remove them.
Change-Id: I3ce4517368fc82aac4eb81c801d6f81a8536e169
* Update karbor from branch 'master'
- Fix unit tests failed
if flow is None for add_tasks when running unit tests,
the method 'add' for flow will be failed. this patch
will fix it.
Change-Id: I1bd70cea69cc54bea34de4b655f6d7caecfdf0e2
* Update karbor from branch 'master'
- Add Python 3 Train unit tests
This is a mechanically generated patch to ensure unit testing is in place
for all of the Tested Runtimes for Train.
See the Train python3-updates goal document for details:
https://governance.openstack.org/tc/goals/train/python3-updates.html
Change-Id: Ia88c2460e015a5ad7b0631e5eece7d51de5788b5
Story: #2005924
Task: #34214
* Update karbor from branch 'master'
- Fix unit tests failed
Currently, zuul test job always failed, it is because the
attribute in SessionClient of nova client has been removed
and use endpoint_override instead, this patch will fix it.
Change-Id: I3101d829ee4382d95acbdc6b756de2b8619b254f
* Update karbor from branch 'master'
- Merge "Add support for image boot server backup with data"
- Add support for image boot server backup with data
This patch added support for image boot server backup with
data. If the image's parent resource is server type, and
the option 'enable_server_backup' is True, it will take
snapshot at first, then backup the new created image by
doing snapshot.
Change-Id: If548e667f44f671278b2b13c19f97a15d867d905
Story: 1712059
Task: 33997
* Update karbor from branch 'master'
- Update api-ref location
The api documentation is now published on docs.openstack.org instead
of developer.openstack.org. Update all links that are changed to the
new location.
Note that redirects will be set up as well but let's point now to the
new location.
For details, see:
http://lists.openstack.org/pipermail/openstack-discuss/2019-July/007828.html
Change-Id: Ib43e63ffdc58615f1ea2d273306c7170a1f97f1b