1129 Commits

Author SHA1 Message Date
Yumeng_Bao
2db279e019 fix Keyerror in test_nova_cdmc
fix keyerror in watcher.tests.decision_engine.cluster.test_nova_cdmc.
TestNovaClusterDataModelCollector.test_nova_cdmc_execute

Change-Id: I44810ae539d8783173dfbb9dd462101e21025802
Closes-Bug: #1698123
2017-06-15 19:08:59 +08:00
Jenkins
986ba9872f Merge "Replace voluptuous with JSONSchema to validate migration action" 2017-06-15 06:21:05 +00:00
Jenkins
44a5a1573c Merge "Replace voluptuous with JSONSchema to validate nop action" 2017-06-14 14:59:22 +00:00
Jenkins
fe34b420a5 Merge "Remove deprecated oslo_messaging.get_transport" 2017-06-14 13:13:34 +00:00
Jenkins
43da4a6d21 Merge "Replace voluptuous with JSONSchema to validate change_nova_service_state" 2017-06-14 13:12:34 +00:00
Jenkins
7ba1bf2237 Merge "Remove log translations and hacking" 2017-06-14 07:41:50 +00:00
Jenkins
206bb413e2 Merge "fix multinode tempest test failure" 2017-06-14 02:27:25 +00:00
Yumeng_Bao
1451d9c134 Replace voluptuous with JSONSchema to validate migration action
Now in watcher,both JSONSchema and voluptuous are used to validate
JSON payloads. We want to remove voluptuous and Use
JSONSchema as our only JSON validation tool to keep consistence
and also to make it easier to expose the validation schema
through our API in future work.

In this patch, we replace voluptuous with JSONSchema to validate
the migration action in watcher applier.

Partially Implements: blueprint jsonschema-validation

Change-Id: I02bff5db9bd06567bcc33b61a316c42c805bb20e
2017-06-12 17:40:07 +08:00
OpenStack Proposal Bot
6d739ae1d0 Updated from global requirements
Change-Id: I8efcebd4dbbaa7fd35085d6378907e5ffa0dd27b
2017-06-10 11:50:38 +00:00
Yumeng_Bao
f2751b4818 Replace voluptuous with JSONSchema to validate change_nova_service_state
Now in watcher,both JSONSchema and voluptuous are used to validate
JSON payloads. We want to remove voluptuous and Use
JSONSchema as our only JSON validation tool to keep consistence
and also to make it easier to expose the validation schema
through our API in future work.

In this patch, we replace voluptuous with JSONSchema to validate
the change_nova_service_state action in watcher applier.

Partially Implements: blueprint jsonschema-validation

Change-Id: I09a03fff96d9555024a74ba255c6951affc39de8
2017-06-10 13:51:25 +08:00
Yumeng_Bao
69730d80b2 Replace voluptuous with JSONSchema to validate nop action
Now in watcher,both JSONSchema and voluptuous are used to validate
JSON payloads. We want to remove voluptuous and Use
JSONSchema as our only JSON validation tool to keep consistence
and also to make it easier to expose the validation schema
through our API in future work.

In this patch, we replace voluptuous with JSONSchema to validate
the nop action in watcher applier.

Partially Implements: blueprint jsonschema-validation

Change-Id: Idf42b3359c36ac9480bd1f1bdd31e756214628ef
2017-06-09 13:14:29 +08:00
Ngo Quoc Cuong
17aa1122da Remove log translations and hacking
Log translation is no longer used, remove translate functions

Change-Id: Ibe205266debd6d39dab0a652a327ab19081ff27a
2017-06-08 09:48:26 +07:00
Ngo Quoc Cuong
d0f5a9fdf5 Remove deprecated oslo_messaging.get_transport
DeprecationWarning:
Using function/method 'oslo_messaging.transport.get_transport()'
is deprecated: use get_rpc_transport or get_notification_transport.

Replace get_transport with get_rpc_transport.

Change-Id: I13455842235a16463e61e5500c9e250a5cc9f86e
2017-06-08 08:34:39 +07:00
Jenkins
32dacdca8b Merge "Cancel Action Plan" 2017-06-07 14:09:32 +00:00
Jenkins
fbfb7159e3 Merge "fix clod_migrate problem" 2017-06-07 10:26:13 +00:00
aditi
d7a44739a6 Cancel Action Plan
This patch adds feature to cancel action plan in watcher.
A General flow from watcher-api to watcher-applier is implemented.

action plan cancel can cancel any [ongoing, pending, recommended]
action plan, it will update the action states also to "cancelled".
For ongoing actions in action plan, actions needs to be aborted.
Seperate patches will be added to support abort operation
in each action.

Notification part is addressed by a seperate blueprint.
https://blueprints.launchpad.net/watcher/+spec/notifications-actionplan-cancel

Change-Id: I895a5eaca5239d5657702c8d1875b9ece21682dc
Partially-Implements: blueprint cancel-action-plan
2017-06-07 05:36:18 +00:00
licanwei
65c63a9351 fix multinode tempest test failure
fix all five tempest tests:
watcher_tempest_plugin.tests.api.admin.test_service.
TestShowListService.test_show_service

watcher_tempest_plugin.tests.api.admin.test_service.
TestShowListService.test_show_service_with_links

tearDownClass (watcher_tempest_plugin.tests.api.admin.
test_action_plan.TestCreateDeleteExecuteActionPlan)

watcher_tempest_plugin.tests.scenario.test_execute_basic_optim
.TestExecuteBasicStrategy.test_execute_basic_action_plan

watcher_tempest_plugin.tests.scenario.test_execute_workload_balancing
.TestExecuteWorkloadBalancingStrategy
.test_execute_workload_stabilization

Change-Id: I4d8945cf2dedea3fa32029d6c07d24a411c1f2e4
Closes-Bug: #1695225
2017-06-07 11:56:23 +08:00
OpenStack Proposal Bot
58d86de064 Updated from global requirements
Change-Id: I65ae1ac5170cf675d8c396ef3b7166bafc19190e
2017-06-06 06:14:58 +00:00
Yumeng Bao
8d84da307b Add rm to whitelist_externals in tox.ini
Fix the following WARNING:

WARNING:test command found but not installed in testenv
  cmd: /bin/rm
  env: /home/jenkins/workspace/gate-watcher-python27-ubuntu-xenial/.tox/py27
Maybe you forgot to specify a dependency? See also the whitelist_externals envconfig setting.

Change-Id: Ie091bd64b6a87c30535ada34daf9d594aa3fdd41
2017-06-05 19:10:28 +08:00
Jenkins
01e865edbf Merge "Replace default cinder endpoint type" 2017-06-05 08:37:45 +00:00
Jenkins
b4b3856f14 Merge "Add action description" 2017-06-02 08:31:21 +00:00
Jenkins
67d065e02a Merge "Remove usage of parameter enforce_type" 2017-06-02 01:26:10 +00:00
Jenkins
891a351a04 Merge "Watcher official install-guide" 2017-06-01 04:38:16 +00:00
Feng Shengqin
f47fd9ac5e Remove usage of parameter enforce_type
Oslo.config deprecated parameter enforce_type and change
its default value to True. Remove the usage of it to avoid
DeprecationWarning: "Using the 'enforce_type' argument is
deprecated in version '4.0' and will be removed in version
'5.0': The argument enforce_type has changed its default
value to True and then will be removed completely."

Change-Id: I59621664773ee5ad264e6da9b15231f30dbb9c40
Closes-Bug: #1694616
2017-06-01 10:13:20 +08:00
Hidekazu Nakamura
7b766680b0 Replace default cinder endpoint type
The default cinder endpoint type is publicURL in cinderclient.
This patch replaces default cinder endpoint type from
internalURL to publicURL.

Change-Id: Ie6951086e4656bd83195dab151dbaaf948113a7c
Related-Bug: #1686298
2017-06-01 01:20:00 +00:00
licanwei
75a025d2d2 Add action description
Add action get_description in class BaseAction.
This information will be sent to the API side via notification.

Partially Implements: blueprint dynamic-action-description

Change-Id: I9ce1b18ad8c5eb7db62ec926d1859d0f508074b0
2017-05-31 18:03:19 +08:00
Jenkins
590bd43a1d Merge "Trivial fix typos" 2017-05-31 08:54:56 +00:00
Jenkins
d2e42a835b Merge "Deleted audit record still get by 'audit list'cmd" 2017-05-31 08:54:15 +00:00
Jenkins
a34e55e47a Merge "Replace oslo_utils.timeutils.isotime" 2017-05-31 08:49:41 +00:00
aditi
a62acbf2ab Watcher official install-guide
Currently watcher project does not have an official
install guide at [1]

This patch adds watcher install guide for rdo and debian.

install-guide is written following the document [2].

[1] https://docs.openstack.org/project-install-guide/ocata/
[2] https://docs.openstack.org/contributor-guide/project-install-guide.html

Change-Id: Idfae7286003f81222dadf91ddcaf95a42c7eb07f
2017-05-31 08:40:27 +00:00
Vu Cong Tuan
35074edaf7 Trivial fix typos
Change-Id: I4c7d3a0d815a616d1ba2c0d26135db5f2aea0c2f
2017-05-30 15:55:33 +07:00
Luong Anh Tuan
dd4aac4092 Replace oslo_utils.timeutils.isotime
Function 'oslo_utils.timeutils.isotime()' is deprecated in version '1.6'
and will be removed in a future version. We use
datetime.datetime.isoformat() instead. For more informations:
http://docs.openstack.org/developer/oslo.utils/api/timeutils.html#oslo_utils.timeutils.isotime

Change-Id: I17384c369fdc7f86b37fd62370d800ed2463adbe
Closes-Bug: #1514331
2017-05-29 23:34:03 +07:00
Jenkins
bd8151e581 Merge "Reduced the code complexity" 2017-05-29 09:15:26 +00:00
Jenkins
8585e49359 Merge "Updated from global requirements" 2017-05-27 12:23:06 +00:00
Jenkins
5d3af47b7d Merge "Versioned Notifications for service object" 2017-05-27 12:20:45 +00:00
OpenStack Proposal Bot
1001525664 Updated from global requirements
Change-Id: I1baa46eba0e7dbae816dbbeb0914f4e1efc8fa0a
2017-05-26 17:31:36 +00:00
licanwei
a33f40ec21 Deleted audit record still get by 'audit list'cmd
Audit record was deleted but the field 'state' maybe not set DELETED.
get_audit_list's filter used field 'state' will get
wrong result.
filter rule should use field 'deleted_at' instead of field 'state'.
get_action_list and get_action_plan_list have the same filter rule.

Change-Id: I08b2a005ca5fb7c2741ac5ed97c6e6b4279758ed
Closes-Bug: #1693666
2017-05-26 14:53:32 +08:00
Vladimir Ostroverkhov
d2a8454043 Versioned Notifications for service object
Implements: blueprint service-versioned-notifications-api

Change-Id: I9d601edb265ee230104f6c63a5f044869aeb3a02
2017-05-25 12:52:01 +03:00
suzhengwei
27c56a19e4 fix clod_migrate problem
1.TypeError: watcher_non_live_migrate_instance() got an unexpected keyword
  argument 'dest_hostname'
2.Conflict: Cannot 'stop' instance ****** while it is in vm_state stopped
  (HTTP 409)

Closes-Bug: #1693434

Change-Id: I7293dd5d08e33c2e534d072da8592172bc438c9e
2017-05-25 07:27:26 +00:00
Jenkins
9bb1e653d8 Merge "Change cinder api_version to '3' in default" 2017-05-25 06:51:58 +00:00
Akihito INOH
bb536ee40d Change cinder api_version to '3' in default
Block Storage API v2 is deprecated now. Instead of it, we should use v3
in default (api_version).

This patch replace cinder default api_version from '2' to '3' in
conf/cinder_client.py

Change-Id: I53ffa74cdac7ac31c74937bf18da8ed2fec92223
Closes-Bug: #1691104
2017-05-25 09:26:33 +09:00
OpenStack Proposal Bot
a0bf1b7d70 Updated from global requirements
Change-Id: Id71f841aa19c8cc07205a59450ea376d4a7ffce4
2017-05-24 03:47:55 +00:00
Jenkins
40f6eea637 Merge "Remove the deprecated tempest.test.attr" 2017-05-22 09:38:12 +00:00
suzhengwei
6c5a3910a7 doc error for WeightPlanner
Change-Id: I6c51a919baa32e9b46bfadfcf8e6afac27890b17
2017-05-22 16:08:53 +08:00
Ngo Quoc Cuong
a4fac69d85 Remove the deprecated tempest.test.attr
[1] moves the attr decorator from test.py to tempest/lib. So, all the
references to tempest.test has to be moved to tempest.lib.decorator.

[2] https://review.openstack.org/#/c/456236/

Change-Id: If977e559d9f3b982baf2974efef3c5b375f263b9
2017-05-22 10:11:18 +07:00
Luong Anh Tuan
21994297cf Replace assertRaisesRegexp with assertRaisesRegex
This replaces the deprecated (in python 3.2) unittest.TestCase
method assertRaisesRegexp() with assertRaisesRegex().

Change-Id: I38c3055288034aba51c11bb1bccd3655f760cecc
Closes-Bug: #1436957
2017-05-19 18:06:00 +07:00
OpenStack Proposal Bot
8a818c9071 Updated from global requirements
Change-Id: Id3b644be5dccdf4abf60c6a49400f61582f0d244
2017-05-17 04:00:56 +00:00
Jenkins
041fcb4ca0 Merge "Added tempest test for workload_stabilization" 2017-05-17 01:32:13 +00:00
Jenkins
a8d765bb28 Merge "Fix a typo" 2017-05-10 18:22:08 +00:00
zhangjianfeng
2b152bf17c [bugfix]for division use accurate division
for now / just get int value ,this will lead method
filter_destination_hosts return 0 host
because self.threshold / 100 * host.vcpus is 0
so we need use accurate division to change this

close-bug: 1689269

Change-Id: I5663951ce750d6c4580a507ccfc0268baea0685f
2017-05-08 18:27:24 +08:00