Migration action with migration_type 'cold' does not work.
This patch fixes nova_helper to follow Pike release python-novaclient.
Change-Id: I0637cefad68cd4b7077a5d3e6b5db5562e7f2917
Closes-Bug: #1736624
This patch set follows deprecation steps
and changes default datasource to gnocchi
Closes-Bug: #1735180
Change-Id: I3b7ec47af7707359373a424a6469d28cbf9ce177
This patch removes 'audit_scope' from __init__ of
BaseClusterDataModelCollector class, as it is a singleton class
and cannot be instantiate more than once.
A new method is defined in BaseClusterDataModelCollector in place
of property audit_scope_handler, which takes audit_scope as
argument.
Change-Id: I0664c151d71a711c118d43c180d8b0760b1c81fa
Closes-Bug: #1732849
In one integrated cloud env, there would be many solutions, which would
make the compute resource strongly relocated. Watcher should listen to
all the notifications which represent the compute resource changes, to
update compute CDM. If not, the compute CDM will be stale, Watcher
couldn't work steadily and harmoniously.
Change-Id: I57173f0cce0717aa36c5ff758d972d38013e3ef8
Implements:blueprint listen-all-necessary-notifications
This patch adds notfication changes after changing the type
of global_efficacy in ActionPlan objects.
Change-Id: I1116cf1d19e4b19e19789f943a631d0400871766
Partially-Implements: blueprint multiple-global-efficacy-indicator
The app.wsgi file should be adjusted to meet pep8 standards and
apply pep8 check to app.wsgi automatically.
Change-Id: I34ec9ce56a329ede76d3d69f6e973d66350d85d1
This patch does step 1 in the docs: Move Legacy Jobs to Projects.
Partial-Implements: blueprint migrate-to-zuulv3
Change-Id: I0c0713260c2dfa2ba64a5746c342db01c1bc3d75
The os-testr 1.0.0 release had a couple of required config changes due
to it's internal usage of stestr. This commit fixes those by adding a
.stestr.conf (to remove a warning) sets the fixture env variables in
the tox.ini instead of being hidden in .testr.conf and removing the
quotes around posargs to make passing args to ostestr actually work.
Also to keep the expected dev experience stestr is used directly for
places where ostestr was called directly.
Change-Id: I785b0dc1720328b119f0978aa573ad0b89e54c75
Closes-Bug: #1731155
This patch update the global efficacy for server consolidation
strategy, test cases and general format.
Change-Id: I62af1e4be415998669f938b3d587c1ccf4293419
Implements: blueprint multiple-global-efficacy-indicator
According to "code conventions" [1], do not use "-y" option.
Instead, use apt-get install package, yum install package,
or zypper install package.
[1] https://docs.openstack.org/doc-contrib-guide/writing-style/
code-conventions.html
Change-Id: I174c8a0c653e322bbf951d72445b1a43251baa7e
If server migration fails, the while loop will not break
until retry to 0,
we can check the task_state to avoid this situation.
Closes-Bug: #1728476
Change-Id: I07e1048eb736263a261456ee78c96fee9db13cb5
Use https instead of http to ensure the safety without containing our
account/password information
Change-Id: I2e4f120f1d57c6c666d65a9a279eddefd112bf23
If scheduler uses db job store, the self.scheduler is None
beacuse execute_audit is class method.
We get [] from self.scheduler.get_jobs()
and can't remove the cancelled audit.
Change-Id: I1768c847465bbefbc9794281328edb07fea83b03
Closes-Bug: #1726345
This patch updates document and add release note for cdm-scoping.
Change-Id: I8e9099aa5caf6bf17ea912e7b1a600af3b6d519d
Partially-Implements: blueprint cdm-scoping
Use https instead of http to ensure the safety without containing our
account/password information
Change-Id: I16bdf6067fba4ea841071100d68edae7750946de
1. Update the instance migration link
2. remove the unnecessary install-guide link
configure and install Ceilometer by
https://docs.openstack.org/ceilometer/latest is enough
remove the other link.
Change-Id: I2bf408de1023750a3d1f2c9e25293649d99ac428
There are more than one 'migrating' status in the volume migration.
Others include starting, completing and so on.
So we should check the final status 'success' and 'error'.
Change-Id: I8ee9330aa32ec4516f2bf9e046ea68a72bc8a53d
https://github.com/openstack/python-novaclient/blob/
master/novaclient/v2/servers.py#L468
From nova api version 2.25(Mitaka release), the default value of
block_migration is None which is mapped to 'auto'.
So we can remove 'block_migration' from live_migrate_instance.
Change-Id: I75a581d3146824b1146e2acf5a7fbe4f8368a4e8
There is already define version_string in version.py
So we don't need generate version in other files, just call it.
Change-Id: I7d8294860523eedad92e213ad00569829e120c39
As of Nova API microversion 2.47, response of GET /servers/detail has flavor
which contains a subset of the actual flavor information used to create the
server instance, represented as a nested dictionary.
Since current watcher nova default api version is 2.53(Pike), This patch
follows the API response change.
Change-Id: Ia575950f0702afa1d093f03ca8ddedd3c410b7de
Closes-Bug: #1722462
This patch removes, explicitly enabled neutron from local.conf
as devstack now default uses neutron
Change-Id: Icf6bd944dd2262ff23cbcceb762a9ba80f471dbb
This patch fixes TypeError of range() in function chunkify, as
range() integer step argument expected, but got str.
Change-Id: I2acde859e014baa4c4c59caa6f4ea938c7c4c3bf
Since default workflow engine action container do_execute method
does not raise exception when action failed, workflow engine action
container execute method never raise exception and
action plan state becomes always SUCCEEDED.
This patch fixes default workflow engine action container do_execute
method to raise exception when action does not return True.
Change-Id: I7eeef69dbdfb5d40e3cf0b1004cbfe199a16bf7b
Closes-Bug: #1719793
Since packages for openSUSE and SLES are not provided,
this patch removes installation guide for openSUSE and SLES.
Change-Id: Ic15d8c4b262e935c7acaef41e18960d0b259d5c9
Closes-Bug: #1715032
This patch adds Notifications for cancel action plan
operation.
Change-Id: I5a89a80729349e3db43ca35ff9fbe8579e86b3b1
Implements: blueprint notifications-actionplan-cancel
disk_over_commit flag was removed in Nova API microversion 2.25(Mitaka).
Since current watcher nova default api version is 2.53(Pike),
this patch removes disk_over_commit flag.
Change-Id: Ib141505b9e8cb41997b29c1762e387b1f84f5143
Closes-Bug: #1720054
As of now we can not know what was happend when migrate action
failed critically.
This patch adds exception log when migrate action failed critically.
Change-Id: I54d0bc54ee1df6f13754771775c58255f53f5008
At various places in watcher code, we are using property getters
to set property, in this way the property setters defined are
never used, this patch fixes to use property setters to set
property.
Change-Id: Idb274887f383523cea39277b166ec9b46ebcda85
python-subunit is not used directly anywhere
and it is dependency of both testrepository
and os-testr
(probably was used by some tox wrapper script before)
Change-Id: I89279430554bc522817c4e2685afef0d95c641dd
add 'disabled_reason' filed into 'ComputeNode' resource, to distinguish
which nodes are disabled by Watcher and which are not by Watcher.
Implements:blueprint extend-node-status
Change-Id: I7175f14870834a4582e45309529d7e8d9fbb2e6f
This patch set replaces create_schema with upgrade to fix
apscheduler creation issue. It also fixes pep8 warnings to
d09a5945e4a0_add_action_description_table.py
Change-Id: Ica842d585ee3a9cd67e45eb1d7bb1916573d7c9c
The return value of ironic_client.node.set_power_state is None, so it's
useless to return the result.
We should check the node state until it's changed or timeout.
Change-Id: I31f75a2c4a721ce4481e6ae7fb83d154a443dad9
Closes-Bug: #1713655
This Patch fixes gate failure, encountered in recent version
of oslo_messaging.
Change-Id: I6d8ab882a7c157dcf4f78c805a4ce2d9b1fa3f14
Closes-Bug: #1716476
iso8601.UTC is correct datetime UTC field object.
iso8601 >= 0.1.12 includes only iso8601.UTC for python3
while both UTC and Utc() for python2. Less then 0.1.12
included both UTC and Utc() for both python2/3.
Change-Id: I0f8796fba6725eea013b3f8d9ad33c10a402c524
Closes-Bug: #1715486
AverageCpuLoad and MigrationEfficacy efficacy indicators are not used.
This patch removes unused indicators.
Change-Id: I2b21defd442c135d26f8fd45f6faf9f67c770bde
Gnocchiclient uses keystoneauth1.adapter so that adapter_options
need to be given.
This patch fixes gnocchiclient creation.
Change-Id: I6b5d8ee775929f4b3fd30be3321b378d19085547
Closes-Bug: #1714871
Audit scope JSON schema should restrict key of host_aggregates
to "id" or "name", but that is not working now.
This patch fixes DEFAULT_SCHEMA to validate host_aggregates.
Change-Id: Iea42da41d61435780e247736599a56c026f47914
Closes-Bug: #1714448
Diffrent stratege has diffrent default scope, restrict them to their
default scope will avoid usage problems.
1)workload_balancing/thermal_optimization/airflow_optimization goals
react on enabled nodes, so restrict default scope to compute nodes
with up state and enabled status.
2)server_consolidation goal react on enabled or disabled nodes, So
restrict default scope to compute nodes with up state and
enabled/disabled status.
Change-Id: I7437dee699ee2d3dd227a047196d4d8db811b81e
Closes-Bug: #1714002
Services are now identified by uuid instead of database id to ensure
uniqueness across cells.
GET /os-services returns a uuid in the id field of the response
from API microversion 2.53(maximum in Pike)
This patch set updates default Nova API version to 2.53.
Change-Id: Ib9fefb794eda3c9e75c6a2f5cfdb0e682b8955f3
Closes-Bug: #1709544
Since iter(dict) is equivalent to iter(dict.keys()), it is unnecessary
to call the keys() method of a dict, the dictionary itself is enough
to be referenced. The shorter form is also considered to be more
Pythonic.
This patch removes the unnecessary dict.keys() method calls in api.
This is a part of a larger patch series that removes dict.keys()
method calls.
TrivialFix
Change-Id: I29000f1f05b90d70109fa01393e97e1ebf450c63
During the strategy sync process,
if goal_id can't be found in the goals table,
will throw a KeyError exception.
Change-Id: I62800ac5c69f4f5c7820908f2e777094a51a5541
Closes-Bug: #1711086
Only when True is returned, the action state is set to SUCCEEDED
some actions(such as migrate) will return None if exception raised
Change-Id: I52e7a1ffb68f54594f2b00d9843e8e0a4c985667
By the input parameter "metrics", it makes decision to migrate a VM
base on cpu or memory utilization.
Change-Id: I35cce3495c8dacad64ea6c6ee71082a85e9e0a83
outlet_temperature strategy relies on a datasource config parameter,
which can be either "ceilometer" or "gnocchi". This patch overrides
get_config_opts method of base class to allow specify datasource.
Change-Id: I551401039e26816568a04c7f2151d5b3c7ed269a
Closes-Bug: #1709024
List comprehensions and generator expressions are considered to be more
Pythonic (and usually more readable) than map and filter with lambda.
This patch replaces four usages of [map|filter](lambda ...) with the
appropriate list comprehension or generator expression.
TrivialFix
Change-Id: Ifda9030bb8aa196cb7a5977a57ef46dfefd70fa6
Metric 'memory.usage' depends on balloon driver,
and shows the memory usage inside guest-os,
while 'memory.resident' represents volume of RAM
used by the instance on the physical machine
So, it is more reasonable to use 'memory.resident'
when calculating node utilization
by gathering instances utilization of the node.
Change-Id: I12dff5176bcf6cb103aa44cafd54f9ecd7170864
Watcher fails to load storage plugin in case there is no installed
Cinder in OpenStack services.
This patch set adds collector_plugins parameter under collector
section in watcher.conf. If plugin name is in collector_plugins,
The plugin is loaded.
Change-Id: Ie3c3543216c925d49b772bf5fe3773ca7d5ae437
Closes-Bug: #1707603
compute_model.get_node_by_uuid(node_uuid) will raise a exception
when the compute node isn't in the compute model.
Closes-Bug: #1709004
Change-Id: I667a9dbfcf67f9f895976aadd5300bbea2ffe6f0
monascaclient was recently migrated to
use 'osc' library. Due to that, exception
classes has been changed. This commit adjusts
the exception class to recently released
monascaclient==1.7.0
Depends-On: Ie647221a3ab055e7b150d65ffb9287b44ef834cb
Change-Id: Icfef345c4269ac4cb682049f22a43fdab3d39845
This patch set updates gnocchi repository URL in local.conf.controller
bacause it moved from under openstack to their own repository.
Change-Id: I53c6efcb40b26f83bc1867564b9067ae5f50938d
Currently compute CDM excludes disabled compute node.
This patch set fixes compute CDM to include disabled compute node.
Change-Id: I8236bb73e0d9bb242251c2abfb59ad5693087afa
Closes-Bug: #1685787
This patch updates the state machine diagram for action plan, It
includes new state "cancelling" which is introduced by actionplan
cancel operation
Change-Id: I0af59f2164922c56d59fbad8018e2aecfef97098
In this patch feching resource_id by resource's original_id was added to
statistic_aggregation method.
Closes-Bug: #1707653
Change-Id: I70b9346146f810e2236ccdb31de4c3fedf200568
This strategy now allow us to create action plans with an explicit
set of actions.
Co-Authored-By: Mikhail Kizilov <kizilov.mikhail@gmail.com>
Change-Id: I7b04b9936ce5f3b5b38f319da7f8737e0f3eea88
Closes-Bug: #1659243
1. Update python version from 3.4 to 3.5
2. Update Ubuntu version from 14.04 to 16.04
3. Update Fedora version from 19+ to 24+
Change-Id: Ic5e9bbd126e10697300c6ffd51ff55d0b815d5ca
Currently continuous audit fails once it fails
because continous audit tries to remove job
even if job is not exists.
This patch set fixes it.
Change-Id: Ic461408c97d71e14c57e368f8436b26fe355fa4e
Closes-Bug: #1706857
This patch fixes the hardcoded value of availability zone
in nova-helper, Now nova api is used to get the availability zone
of destination node
Change-Id: I4c5a34946ed404df5bbfe34ce99873d32772dbf4
Add a new table to save the mapping
Add logic to update the table when action loading
Add logic to show the action description
Change-Id: Ia008a8715bcc666ab0fefe444ef612394c775e91
Implements: blueprint dynamic-action-description
Cinder data model was added in Pike cycle and that needs
configuration in cinder.conf for refreshing the model in
real time.
This patch set adds Add Configure Cinder Notifications section
for explaining the configuration.
Change-Id: I41cc870e2d47c56fd7c9fcdd6f03c95fa939c3f2
Now that we replaced voluptuous with JSONSchema in all actions,
this patch replaces voluptuous with JSONSchema in BaseAction
and removes validate_parameters method in each action.
Partially Implements: blueprint jsonschema-validation
Change-Id: I07c907ddfa4a568d7fff42776df02218330d56a0
This patch set fixes devstack plugin by removing head
keyword from watcher-db-manage.
It is related to https://review.openstack.org/#/c/483825/
Change-Id: I3dcea6ae799c94a882e68d66920c5cd87d83d85e
This patch removes the requirement to specify destination node,
for migrate action. There can be some strategies that wants to rely
on nova-scheduler for destination node. It will not impact any current
strategy behavior.
Change-Id: Ia12b2f0b8369e632a7959b28e485d86b6cff83e9
Closes-Bug: #1691056
There are many uselees logging in the decision log file:
Arguments dropped when creating context: {u'global_request_id': None}
Change-Id: I7583b2ff6ea1cc15173536ca1cf08cc9f0ecb20d
Closes-Bug: #1704736
This patch adds abort operation for live migration
to support abort in cancel action plan.
Change-Id: I458e93d9bd09dc4cf80cc941104129fc7600a6b1
Partially-Implements: blueprint cancel-action-plan
wrong parameter passing of function "query_sample"
the default parameter will be recognized as "user_id"
Change-Id: I293b130c3f709dc93cd4b1b7382ae8895a54765d
Closes-Bug: #1703297
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_node_power_state action in watcher applier.
Partially Implements: blueprint jsonschema-validation
Change-Id: If9ffe5e0b107e0da5673247e4d5ec9917790827f
This patch set updates documentation link in README
because of doc migrations.
Depends-On: Iecb4f60efb015a56b9b37331859848b287112842
Change-Id: I5b8a5ec8a328ae275fe6271965ea0077ae301814
This patch set makes the following changes:
* Add index file to each subdirectory of doc/source
* Update doc/source/index.rst with new links
* Move content of install-guide to the doc/source/install
* Minor changes
Depends-On: Ifc5512c0e2373cf3387e0e0498268eab092e52bb
Change-Id: Iecb4f60efb015a56b9b37331859848b287112842
The default neutron endpoint type is publicURL in neutronclient.
This patch replaces default neutron endpoint type from
internalURL to publicURL.
Change-Id: I8162b6178051df5f086488ecfb5d0bdc569ef9cd
Related-Bug: #1686298
The default glance endpoint type is publicURL in glanceclient.
This patch replaces default glance endpoint type from
internalURL to publicURL.
Change-Id: I39451ba89f191693475a694bd5c9045bf3bf539a
Related-Bug: #1686298
There is no action plan if creating audit was cancelled.
In this case, we just return none.
Change-Id: Ia7a93dab5978d181557d7dd7499e83655aec6f40
Closes-Bug: #1700901
In tempest, alias 'manager' has been moved to 'os_primary'
in version Pike, and it will be removed in version Queens.
This patch is to replace the usage of 'manager' with 'os_primary'.
For other details, please check [1] and [2]
[1] https://review.openstack.org/#/c/468036/
[2] https://review.openstack.org/#/c/463484/
Change-Id: I582758c42f61a85a2fd4aac5f7a97cd6021ecf68
When a development environment is under a proxy, tox is failed even if
environment variables of the proxy are set.
This patch fix this problem. Refer patch set [1]
[1] https://review.openstack.org/#/c/189569
Change-Id: I6c0b896a6de1b7193dd4b77b6bc4433d0c75732d
Some of the available checks are disabled by default, like:
[H106] Don’t put vim configuration in source files
[H203] Use assertIs(Not)None to check for None
Change-Id: I369cff1c0f7f3cd3f5bcf3785b6904c9326c6759
When using 'query.filter_by(deleted_at=None)'
Will generate the incorrect SQL 'audits.deleted_at', as below:
SELECT * FROM action_plans INNER JOIN audits ON audits.id =
action_plans.audit_id WHERE audits.uuid = '' AND
audits.deleted_at IS NULL ORDER BY action_plans.id ASC
The correct filter field is 'action_plans.deleted_at'
Change-Id: Ie05f35233f78e82bc7af2c26c9effd62ea5f86ab
Closes-Bug: #1698720
The primary usage of "node.state" is wrong, it should be 'node.status'.
So correct it and refactor the method 'get_state_str'.
Change-Id: I9004c85bfb09f9b41fc56ecb5a56122d523a661f
Added strategy to identify and migrate a Noisy Neighbor - a low priority VM
that negatively affects peformance of a high priority VM by over utilizing
Last Level Cache.
Partially Implements: blueprint noisy-neighbor-strategy
Change-Id: Ia13f7e91a695024410b8f3b3d3d1646a0dd687d4
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
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
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 resize action in watcher applier.
Partially Implements: blueprint jsonschema-validation
Change-Id: I0ee4ba010a9f437658af81d5c971449aefc7f9c4
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 sleep action in watcher applier.
Partially Implements: blueprint jsonschema-validation
Change-Id: I3032490236536a11e7045a56ad0bd40ef979407e
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
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
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
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
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
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
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
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
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
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
[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
This replaces the deprecated (in python 3.2) unittest.TestCase
method assertRaisesRegexp() with assertRaisesRegex().
Change-Id: I38c3055288034aba51c11bb1bccd3655f760cecc
Closes-Bug: #1436957
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
This patch set adds WatcherJobStore class that allows to link
jobs and services.
Partially-Implements: blueprint background-jobs-ha
Change-Id: I575887ca6dae60b3b7709e6d2e2b256e09a3d824
Currently if user wants to skip some host_aggregates from audit,
it is not possible. This patch adds host_aggregates into the exclude
rule of audit scope. This patch also implements audit-tag-vm-metadata
using scopes.
TODOs:
1. Add tests
2. Remove old implementation of audit-tag-vm-metadata
Change-Id: Ie86378cb02145a660bbf446eedb29dc311fa29d7
Implements: BP audit-tag-vm-metadata
The default is publicURL in novaclient.
This also caused the failure of
gate-watcher-dsvm-multinode-ubuntu-xenial-nv.
Change-Id: I485dd62fb7199ffeca29a9b573a624bf144484d1
Closes-Bug: #1686298
Closes-Bug: #1686281
Running py2* post py3* tests results in error. Add
'rm -f .testrepository/times.dbm' command in testenv to
resolve this.
Change-Id: Ia43f8d10f157d988c4d2c89f16cac0ea729cabe6
now when action like live-migration retry is reached
result is False but action still success
we can add check in do execute method can fix this problem.
close-bug: 1685757
Change-Id: I8390566ec8dcfa3a71b931d5be1b305802ac0b2a
If instance_ram_util and instance_disk_util can not get data
from datasource. we can use instance data,
just like total_cpu_utilization
Change-Id: I4170b96946b07435411ada5ff4a14c978c0435b4
oslo.messaging allow dispatcher to restrict endpoint
methods with DefaultRPCAccessPolicy to fix FutureWarning
Closes-Bug:1663543
Change-Id: I0288320193b0153ee223664696abca21cbdb0349
This patch set adds ironicclient.
Change-Id: I122a26465d339ee6e36c0f234d3fd6c57cee2afa
Partially-Implements: blueprint build-baremetal-data-model-in-watcher
New audit state SUSPENDED is added in this patch set. If audit
state with continuous mode is changed from ONGOING to SUSPENDED,
audit's job is removed and the audit is not executed.
If audit state changed from SUSPENDED to ONGOING in reverse,
audit is executed again periodically.
Change-Id: I32257f56a40c0352a7c24f3fb80ad95ec28dc614
Implements: blueprint suspended-audit-state
This patch adds gnocchi support in uniform_airflow strategy
and adds unit tests corresponding to that change.
Change-Id: I347d0129da94a2fc88229d09297765795c5eeb1a
Partiallly-Implements: bp gnocchi-watcher
In DefaultApplier.execute(), Action.list should set eager=True.
Otherwise it will trigger an exception when the notification is sent.
This also causes the FAILURE of
gate-watcher-dsvm-multinode-ubuntu-xenial-nv.
Change-Id: I27db9691727671abb582d4f22283ebda5bd51b07
Closes-Bug: #1676308
Use https instead of http to ensure the safety without containing our
account/password information
Change-Id: I1f164848f164d9694c0cfc802cc3980459bdf12f
This patch adds gnocchi support in outlet_temp_control strategy
and adds unit tests corresponding to that change.
Partiallly-Implements: bp gnocchi-watcher
Change-Id: I2c2e9a86c470f3402adc3dbb7eb9995c643d5b37
This patch adds gnocchi support in workload_balance strategy
and adds unit tests corresponding to that change.
Change-Id: I9bc56c7b91b5c3fd0cfe97d75c3bace50ab22532
Partiallly-Implements: bp gnocchi-watcher
This patch enables gnocchi plugin for devstack.
Partiallly-Implements: bp gnocchi-watcher
Closes-Bug: 1662515
Change-Id: I6614ce6999c9681bd6fafc6c85a3755b5ce8e2dd
This patch adds support to run watcher-api
with mod-wsgi. It provides
1. wsgi app script files, to run watcher-api under apache.
2. updated devstack plugin to run watcher-api default with
mod-wsgi.
3. Document to deploy watcher-api behind wsgi.
Change-Id: I8f1026f0b09fd774376220c2d117ee66f72421b8
Closes-Bug: #1675376
In this changeset, I added a tempest test that is in charge of
executing the workload_stabilization strategy.
Change-Id: I61bad268fc5895ddb22312baeb21da5ae3c71de9
This patch adds gnocchi support in VM-Workload-Consolidation strategy
and adds unit tests corresponding to that change.
Change-Id: I4aab158a6b7c92cb9fe8979bb8bd6338c4686b11
Partiallly-Implements: bp gnocchi-watcher
This commit[1] has removed verbose option due to which our ut's are failing.
This patch is fixing this issue.
[1] https://review.openstack.org/#/c/444217/
Change-Id: I784a7f855f42de462e8fc8f829f5526e1483dab4
Some configuration options were accepting both IP addresses
and hostnames. Since there was no specific OSLO opt type to
support this, we were using ``StrOpt``. The change [1] that
added support for ``HostAddressOpt`` type was merged in Ocata
and became available for use with oslo version 3.22.
This patch changes the opt type of configuration options to use
this more relevant opt type - HostAddressOpt.
[1] I77bdb64b7e6e56ce761d76696bc4448a9bd325eb
Change-Id: Idec43189ff8edc539027ba0b0369e54ae883cd2b
This patch adds gnocchi support in workload_stabilization strategy
and adds unit tests corresponding to that change.
Change-Id: I96bd758962bbf67d60e19a99a19451fb80e447b2
Partiallly-Implements: bp gnocchi-watcher
This patch adds the functionality to filter out VMs which have
metadata field 'optimize' set to False. This patch implements the
functionality for basic_consolidation strategy.
Change-Id: Iaf7b63e09534e4a67406e7f092242558b78c0bde
Partially-Implements: BP audit-tag-vm-metadata
This patch adds gnocchi support in basic_consolidation strategy
and adds unit tests corresponding to that change.
Change-Id: Ia1ee55fca8eadffbd244c0247577805b6856369d
Partiallly-Implements: bp gnocchi-watcher
We have two controllers as HA in our OpenStack environment.
There are watcher-applier and watcher-decision-engine in each
controller. So there are two same name in the services table.
In this case, the objects.Service.get_by_name(context, name)
will trigger exception of MultipleResultsFound.
We should use objects.Service.get(context, id) replace of
objects.Service.get_by_name(context, name).
Change-Id: Ic3ce784590d6c2a648cb3b28299744deed281332
Closes-Bug: #1674196
Those are remnants from the oslo-incubator times. Also, oslo.messaging
deprecated [1] transport aliases since 5.2.0+ that is the minimal
version supported for stable/newton. The patch that bumped the minimal
version for Watcher landed 3 months+ ago, so we can proceed ripping
those aliases from the code base.
[1] I314cefa5fb1803fa7e21e3e34300e5ced31bba89
Change-Id: Ie3008cc54b0eb3d1d02f55f388bd1c3b109d126d
Closes-Bug: #1424728
Check the creation time of the actionplan,
and set the state to SUPERSEDED if it has expired.
Change-Id: I900e8dc5011dec4cffd58913b9c5083a6131d70d
Implements: blueprint stale-action-plan
The scenario tests base class from Tempest is not a stable interface
and it's going to be refactored on Tempest side, as notified in
http://lists.openstack.org/pipermail/openstack-dev/2017-February/112938.html
Maintain a local copy of the base class, taken from Tempest with head of
master at c5f1064759fe6c75a4bc5dc251ed1661845936cb.
Change-Id: Idfa5ebe18c794c51e406156fb120d128478d4f1e
actionplan.save() will send a send_update notification.
This notification need eagerly loaded,
so we should set eager=True for actionplan.list.
Change-Id: Iafe35b9782fb0cc52ba5121c155f62c61ef70e1f
Closes-Bug: #1673679
Currently http is used to access git, however http is not safe enough
since the access information contains our account/password information.
Use https instead of http to ensure the safety.
And for others services such as pypi or python, it's still nice to use
https.
Change-Id: I706a4a1873c6bbc05385057757fc5962344f9371
I extracted some of the functionalities into helper functions
to reduce the length and complexity of build_query (in
watcher/datasource/ceilometer.py).
Additionally it became more readable as well, without
changing its functionality.
Change-Id: I9e5c524754cf0f9d718a216465ba1b7536add80e
This patch adds instance metadata in the cluster data model. This
is needed for Noisy Neighbor strategy.
Change-Id: Ia92a9f97ba1457ba844cc37a4d443ca4354069e3
Since pbr already landed and the old version of hacking seems not
work very well with pbr>=2, we should update it to match global
requirement.
Partial-Bug: #1668848
Change-Id: I5de155e6ff255f4ae65deff991cff754f5777a8d
There are not any endpoints for `ceilometer` with devstack/
local.conf.controller. The service `ceilometer-api` should
be enabled explicitly.
Change-Id: I2218a98182001bef65fbc17ae305cfadf341930e
Closes-Bug: #1667678
In the current audit process, after executing the strategy,
will check whether there are currently running actionplan,
and if so, will set the new actionplan SUPERSEDED.
We can optimize the process to perform this check in pre_execute(),
and if any actionplan is running, no further processing is performed.
Change-Id: I7377b53a2374b1dc177d256a0f800a86b1a2a16b
Closes-Bug: #1663150
Since watcher dashboard can be sucessfully installed now by devstack,
we should enable this again. Many of us are get the local.conf from
here,so this change is necessary, we can enable watch dashboard plugin
by default.
Change-Id: Iad5081a97515b3f831d2f468dc514a942e6d3420
test.call_until_true has been deprecated since Newton on Tempest side,
and now Tempest provides test_utils.call_until_true as the stable
library method. So this patch switches to use the stable method before
removing old test.call_until_true on Tempest side.
Change-Id: Iba2130aca93c8e6bccb4f8ed169424c791ebc127
Needed-by: Ide11a7434a4714e5d2211af1803333535f557370
Improves tracking independent workflows. A log adapter
was added to provide an easy means of prepending publisher
ID and event type information.
Change-Id: I5d2d8a369f99497b05c2a683989e656554d01b4f
Closes-Bug: 1642623
This patch adds checking audit state when updating an existing audit
in accordance with audit state machine.
Closes-Bug: #1662406
Change-Id: I20610c83169b77f141974a5cebe33818a4bf0728
The argument to the add_edge function should be instance.uuid
and node.uuid, not instance and node
Change-Id: Ida694f9158d3eb26e7f31062a18844472ea3c6fa
Closes-Bug: #1662810
The gating on python 3.4 is restricted to <= Mitaka. This is due to
the change from Ubuntu Trusty to Xenial, where only python3.5 is
available. There is no need to continue to keep these settings.
Change-Id: I3b3f0b08f6f27322b8a9d99eb25984ccd6bfe7a6
The 'strategy_id' attribute is the one that not exposes
to API. But the 'PATCH' API always update this attribute.
So this change does not work when choose 'remove' op.
This patch sets value for 'strategy_id' attribute.
Change-Id: I1597fb5d4985bb8271ad3cea7ea5f0adb7de65f4
Closes-Bug: #1662395
When action plan is currently running, new action plan is set as
SUPERSEDED and error log reported. This patch changes log level
from error to warning.
Change-Id: I931218843d8f09340bd5363256164807d514446b
Closes-Bug: #1662450
'watcher audit list' returns a incorrect auto trigger flag
auto_trigger field is incorrectly unset to False
Change-Id: Iba4a0bda1acf18cbfde6f1dcdb0985a4c3f7b5bb
Closes-Bug: #1662051
Alembic provides command script to update a relational
database, using SQLAlchemy. I provide in this patchset the
initial version python script for create a Ocata db version.
Implements: blueprint db-migration
Change-Id: I7bda4286bc8141bb4fcfba3837070966ef506b5d
This patch set adds new period strategy input parameter
which allows allows to specify the time length of
statistic aggregation.
Partial-Bug: #1614021
Change-Id: I1a276206e5b2c05d8f94acdeb866c8822fa84f35
The mocks on _get_alarm_client() are now failing because it was renamed
as _get_redirect_client(). This fix reflects this name change.
Change-Id: Id61e74dc4adc0c939661462953b322d65104a651
Here is a new architecture diagram with some updates on the
glossary and on descriptions of architecture elements.
I also fix some warning logs.
Closes-Bug: #1657405
Change-Id: I442082d702fc8667e9397c090da51ca1ead5d86e
This patch set allows to execute Watcher Actions in parallel.
New config option max_workers sets max number of threads
to work.
Implements: blueprint parallel-applier
Change-Id: Ie4f3ed7e75936b434d308aa875eaa49d49f0c613
In this changeset, I use https://review.openstack.org/#/c/362730/
as an example to make the existing ModelRoot fully graph-based.
Change-Id: I3a1ec8674b885d75221035459233722c18972f67
Implements: blueprint graph-based-cluster-model
If we define an audit scope with a exclusion rule composed
with compute nodes, the compute model built is empty. I fix
the algo used to built this scoped compute model.
Change-Id: I675226c58474b7ea52b3f92e7b466adae40643b8
Closes-bug: #1658995
An action plan can be now go to SUPERSEDED state if another
action plan is on going for instance. It could be the case with
tempest test, because we can have several scenario tests running
at the same time.
Change-Id: I5449e545676463f0ea601e67993e9dffa67929a7
Closes-bug: #1657031
As instance migration cost is petty compared to the cost of
compute node release, I update the way to compute the global
efficacy for a server consolidation goal. The new formula is simplest
and it's only based on compute node.
Change-Id: Ibcce31a85af70429f412c96c584a761d681366a2
In the optimize solution stage when launching audit
based vm_workload_consolidation strategy.
The instance map in node should change when migration
action was removed. Otherwise a KeyError exception
will be thrown.
Change-Id: I054b6b12922892a02d155b4ddc001b19890d32c5
Closes-Bug: #1656157
Add a script command to enable Nova compute.instance.update
notifications on VM and task state changes.
Change-Id: I639f003d92e184085a332f53c6783e5eca0002fe
Getting images from Novaclient is refered as proxy API
and was deprecated to use in nova. We should use
Glanceclient to get images instead.
Closes-bug: #1655516
Change-Id: Ie7d89e857d149e11b3c9b44c980b0be5cb0cc35f
In this changeset, I added the support for both Monasca and
Ceilometer for the basic_consolidation strategy.
Partially Implements: blueprint monasca-support
Change-Id: Ide98550fbf4a29954e46650190a05be1b8800317
In this changeset, I implemented a Helper class to deal with
Monasca requests.
Change-Id: I14cfab2c45451b8bb2ea5f1f48254b41fa5abae8
Partially-Implements: blueprint monasca-support
By calling solution.add_action with no input_parameters, TypeError:
'NoneType' object does not support item assignment was occurred.
This patch fix it.
Change-Id: Ia2ad0c18bc20468ca73c0ab70495fac2c90e0640
Closes-Bug: #1647927
This patch set adds support of auto-triggering of action plans.
Change-Id: I36b7dff8eab5f6ebb18f6f4e752cf4b263456293
Partially-Implements: blueprint automatic-triggering-audit
When we receive a incoming 'service.update' notification
from nova, with disabled: false, we should set the related
compute node status to ENABLED.
Change-Id: Ib8075a5cf786f81ec41423805433f83ae721cbbd
Closes-bug: #1650485
Implemented db config module
Partially Implements: blueprint centralise-config-opts. Also moved
basedir_def, bindir_def and state_path_def to watcher.conf.paths
Change-Id: I73d201f6a23bbdb1c6189434b11314a66620e85c
For multinode setup, a couple of updates to /etc/nova/nova.conf was
needed for live migration.
serial_console needed to be disabled and vncserver_listen needed to
be set to any for the vncserver to accept connections from all of the
compute nodes.
Change-Id: I62ebc2a07ca525bd80da130981f337806b2b89ae
Closes-Bug: #1649638
add_migration(self, instance_uuid, source_node,
destination_node, model)
param source_node: node object
param destination_node: node object
but in optimize_solution(), The incoming parameters are
source_node_uuid and destination_node_uuid.
This causes an exception:
AttributeError: 'unicode' object has no attribute 'state'
Change-Id: Ia27f219caa007f2b49ff9efc2544d5b4d894fe65
Closes-Bug: #1649441
Specific exception should be thrown when cluster state
is stale. Current usage is to raise this exception if
compute_model.state is True.
Bug was describeid by Jean-Emile DARTOIS.
Change-Id: Iaddb4cc8007c51bb14759c9da829751e834499d0
Closes-Bug: #1621855
At present, In the sync function, there is no check about the
parameters_spec field in strategy table, if the parameters_spec
field content has changed, Such as increased 'periods' parameter,
strategy table will not be updated, the program will run abnormal.
exception msg:
2016-12-05 11:11:39.138 TRACE watcher.decision_engine.audit.base
raise AttributeError(name)
2016-12-05 11:11:39.138 TRACE watcher.decision_engine.audit.base
AttributeError: periods
Change-Id: I84709c246acbdf44ccac257b07a74084962bb628
Closes-Bug: #1647521
The goal of "vm_consolidation" is not existent by default.
Use the goal of "server_consolidation" instead for shell command.
Change-Id: Icef5536a337fa88a4504e23e4de6d2e96c45d7b6
doc/source/deploy/configuration.rst
* 'The Watcher system is a collection of services
that provides support to optimize your IAAS plateform. '
Fix: Typo, plateform -> platform
* Additionally, the Bare Metal service has certain
external dependencies, which are very similar to
other OpenStack services:
Fix: Bare Metal -> Watcher
* Please check your hypervisor configuration to correctly
handle instance migration.
Fix: ref of ``instance migration`` is http://docs.openstack.org/
admin-guide/compute-live-migration-usage.html
Change-Id: I00ab282a0f9ffcfddf745df1dd67418a43d70b10
Closes-Bug: #1646290
There is not module 'messaging.utils' in 'watcher.common'
but module 'synchronization' instead.
Change-Id: If2d585a4f416614cbe91e4ef61fc7473508d38af
Closes-Bug: #1643862
One space was missed between 'the' and ':ref' in
'the:ref:Watcher Database <watcher_database_definition>'.
Change-Id: I3e46121dc7c30f73df4ca455e2c629929cdbd2ec
Closes-Bug: #1644388
This patch set adds new periods strategy input
parameter that allows to specify the time length of
statistic aggregation.
Change-Id: Id6c7900e7b909b0b325281c4038e07dc695847a1
In this change set, hardware.cpu_util is changed to
compute.node.cpu.percent in workload_stabilization.
By doing so, one can run this strategy on a simple devstack
without having to setup the SNMP plugin.
Change-Id: I8df8921337ea3f4e751c0c822d823e64e3ca7e1c
I this changeset, I fixed the issue whereby object auto fields are not
being updated within the WatcherObject after an update.
Change-Id: I7e65341b386a5c0c58c2109348e39e463cf2f668
Closes-Bug: #1641955
In this change set, Default value 'hardware.cpu_util' of instance_metrics
was changed to 'compute.node.cpu.percent'.
Change-Id: I02f87e5fea663e2e04c61cc36b7d55ff250bf8cc
In this changeset, I implemented the main logic although this is
mainly a shameful copy/paste of Nova's blueprint
https://blueprints.launchpad.net/nova/+spec/centralize-config-options
Partially Implements: blueprint centralise-config-opts
Change-Id: Ib645ad5da5c706336bb6ac37e85b027d05665c32
In this changeset, I implemented the following notifications:
- audit.planner.start
- audit.planner.end
- audit.planner.error
Partially Implements: blueprint audit-versioned-notifications-api
Change-Id: I29d371f8cb3fd7948c87bec97186e24a88e8fdb6
In this changeset, I implemented the following notifications:
- audit.strategy.start
- audit.strategy.end
- audit.strategy.error
Partially Implements: blueprint audit-versioned-notifications-api
Change-Id: I6ae8468caf8d215bc8bc694813beb4dc94f53fdb
In this changeset, I implemented the audit.delete notification.
Partially Implements: blueprint audit-versioned-notifications-api
Change-Id: I8aeb73f4b8d3273d6de7dc9c44674e3041b005ea
In this changeset, I implemented the audit.create notification.
Change-Id: Ia092ca3a3dc951e3313a07f15a98aec5818e9ab0
Partially-Implements: blueprint audit-versioned-notifications-api
In this changeset, I implemented the sending of update notifications
whenever an audit is modified.
Change-Id: I5ccc2516ce896ae7d4ef542b133e8f052eaed602
Partially-Implements: blueprint audit-versioned-notifications-api
In this changeset, I updated the devstack plugin so it has the
necessary configuration options for it to emit the Watcher
notifications straight out of the box.
Partially Implements: blueprint watcher-notifications-ovo
Change-Id: I048e0b82cde40bd3699c90429bdf55ee235fff3b
In this changeset, I implemented the notification_level parameter
that allows you to set the level minimum level of notification to
be emitted by Watcher.
Partially Implements: blueprint watcher-notifications-ovo
Change-Id: I78b30ceb3ee7606078a87beb3a4ce5d9568af1e0
In this changeset, I removed the now obsolete status_topic config
option.
DocImpact
Partially Implements: blueprint watcher-notifications-ovo
Change-Id: Icfc03abd875b77fc456bfa286ac2b5774651e8fa
In this changeset, I cleaned up the Watcher codebase to remove
the old notification mechanism that is actually unused.
Partially Implements: blueprint watcher-notifications-ovo
Change-Id: I1901e65f031441b98a7d6f6c9c1c0364eaaaf481
In this changeset, I added a new Sphinx directive (from Nova) that
allows us to automatically display notification samples for of
all the upcoming notifications in Watcher.
Partially Implements: blueprint watcher-notifications-ovo
Change-Id: Id7d819ee21db6dc616c78faea483b883f77e3bd6
In this changeset, I added all the required modification in order
for Watcher to enable the implementation of versioned notifications.
Change-Id: I600ecbc767583824555b016fb9fc7faf69c53b39
Partially-Implements: blueprint watcher-notifications-ovo
This patch adds documentation on requirements for
vm_workload_consolidation strategy.
Change-Id: I304644138b34658b09f7cd8f29eb089757807b61
Closes-bug: #1640820
This patch set removes extra field from rally tasks
since Watcher team has removed extra field from
watcher and python-watcherclient projects.
Change-Id: Ib1640cbe8668f56f3a3a54e9f73bb1e3e6747d79
This patch set allows in case of NoMetricValuesForInstance exception
to continue the flow of Workload Stabilization strategy
instead of interrupting.
Closes-Bug: #1640096
Change-Id: I2de22bb97defb9c34e409102d06846275793b80d
The function nova.servers.list() will return a huge context in the
large infrastructure. We can use nova.servers.get() instead of it.
Change-Id: If922c31e8aff27bfbc475c63083ee561ee7f1f67
Submitted state is not referenced nor used in the Watcher codebase,
and hence removed the references to the state from the codebase.
Change-Id: Ibb0cf5125e2d93683739abf35030b7cf5cb1b056
Closes-Bug: 1634150
In this changeset, I added the "action_plan" ObjectField which can
either be loaded by setting the new "eager" parameter as True
or not loaded (as before) by setting it to False. The advantage of
introducing this eager parameter is that this way,
we can reduce to a minimum the overhead of DB queries whenever the
related object fields is not actually needed.
Change-Id: Iae255d9a0a919e2b6db710be24dbf9033b72166e
Partially-Implements: blueprint watcher-versioned-objects
In this changeset, I added the "audit" and the "strategy "ObjectField
which can either be loaded by setting the new "eager" parameter as True
or not loaded (as before) by setting it to False.
The advantage of introducing this eager parameter is that this way,
we can reduce to a minimum the overhead of DB queries whenever the
related object fields is not actually needed.
Change-Id: Ieca6fa438cbf2267f5ae2ea0d059b2953e65076b
Partially-Implements: blueprint watcher-versioned-objects
In this changeset, I added the "goal" and the "strategy "ObjectField
which can either be loaded by setting the new "eager" parameter as True
or not loaded (as before) by setting it to False.
The advantage of introducing this eager parameter is that this way,
we can reduce to a minimum the overhead of DB queries whenever the
related goal is not actually needed.
Change-Id: I5a1b25e395e3d904dae954952f8e0862c3556210
Partially-Implements: blueprint watcher-versioned-objects
In this changeset, I added the "goal" and the "strategy "ObjectField
which can either be loaded by setting the new "eager" parameter as True
or not loaded (as before) by setting it to False.
The advantage of introducing this eager parameter is that this way,
we can reduce to a minimum the overhead of DB queries whenever the
related goal is not actually needed.
Change-Id: I97418163f68aea2f1cda80be94e4035f0b3700ae
Partially-Implements: blueprint watcher-versioned-objects
In this changeset, I added the "goal" ObjectField which can
either be loaded by setting the new "eager" parameter as True or
not loaded (as before) by setting it to False.
The advantage of introducing this eager parameter is that this way,
we can reduce to a minimum the overhead of DB queries whenever the
related goal is not actually needed.
Partially-Implements: blueprint watcher-versioned-objects
Change-Id: I103c9ed161d2cedf7b43c55f9e095ef66bf44dea
In this changeset, I modified all existing Watcher objects to now
rely on oslo.versionedobjects as a base.
Change-Id: I3c9b1ca6da529d128743b99020350f28926ea1a2
Partially-Implements: blueprint watcher-versioned-objects
As we are about to version the Watcher objects, we need to make sure
that upcoming model/object modifications are additive in order to
avoid having to bump the major version of the API. Therefore,
this changeset removes 4 unused DB fields that were exposed in their
associated Watcher objects (i.e. AuditTemplate and Audit).
Change-Id: Ifb0783f21cd66db16b31e3c8e376fc9d6c07dea3
Partially-Implements: blueprint watcher-versioned-objects
In this changeset, I added ORM relationships to the DB models
concerning the already-declared foreign keys.
I also modified the DB query building to now handle a new 'eager'
parameter that, if True, is responsible to also fetch the data
relative to these 'parent' DB entities (no cascading).
Change-Id: Ieea181af9a4b173c54621dcc6c549161f5a35aeb
Partially-Implements: blueprint watcher-versioned-objects
This patch is deprecated use xx = [] for the parameter initial value,
this parameter will only be initialized at the first call,this is not
what we expected.
Better choice is to set the initial value to None,
then initialize xx with xx= xx or [] in method body.
More details:http://effbot.org/zone/default-values.htm
Change-Id: Iee0648fd500422f48c3f7f35b5066fdc644ae308
This patch set normalizes CPU for hardware.cpu.util meter and
transform KB into MB fetched from hardware.memory.used meter.
Change-Id: I6dd1d053e81f06c3adb6fb256ac77bbf55a07f3e
Developer should provide a detailled documentation about his strategy
algorithm to make it even easier to use by a Watcher end user.
I propose in this changeset a template for strategy documentation.
you will find also a example with basic consolidation strategy.
Change-Id: I66da1a33b87a94b508dd23ac7dce4cae6f4e068b
watcher already uses PBR:-
setuptools.setup(
setup_requires=['pbr>=1.8'],
pbr=True)
This patch removes `MANIFEST.in` file as pbr generates a
sensible manifest from git files and some standard files
and it removes the need for an explicit `MANIFEST.in` file.
Change-Id: If1b80738e28d71fd9e9bb4939f94adfd721a041a
Closes-Bug:#1608980
This patch set adds audit scope mechanism.
It also removes host_aggregate field.
Change-Id: Ia98ed180a93fc8c19599735e2b41471d322bae9a
Partially-Implements: blueprint define-the-audit-scope
This patch set adds service object to the watcher_db_schema_diagram.txt
New watcher_db_schema_diagram.png is compiled and attached.
Partially-Implements: blueprint watcher-service-list
Change-Id: Ibaac9020b0cb9fb147259a8685a7a072216ff95d
This patch set adds supervisor mechanism for Watcher services
to get ability to track states.
Partially-Implements: blueprint watcher-service-list
Change-Id: Iab1cefb971c79ed27b22b6a5d1bed8698e35f9a4
In this changeset I added a Model abtract base class for models
and updated the plugin docs to reference it. I also added the
CDM and CDMC acronyms to the glossary.
Change-Id: Ie7d76a9f84d545715fa6e5bf350b9d2321bab9e1
Releasenote translation publishing is being prepared. 'locale_dirs'
needs to be defined in conf.py to generate translated version of the
release notes.
Note that this repository might not get translated release notes - or
no translations at all - but we add the entry here nevertheless to
prepare for it.
Change-Id: I67b2202570e23d3f20f7d132b7d7dbb460a2af3f
In this changeset, I added composite contraints on models that
were currently subject to an implicit uniqueness.
This composite constraint takes as an input the name and the deleted
columns.
The 'deleted' column is 0 by default and is updated with the value of
the associated 'id' column upon soft deletion.
What this means is that this composite constraint guarantees the fact
that we can hold many soft deleted records holding the exact same name.
Indeed, the value of the deleted column will be different whilst
forbidding 2 non-soft deleted records with the same name as their
associated 'deleted' value will be 0 and subsequently violates the
constraint.
Change-Id: I3ee39e23aa4ca9bc6b4ea9af8c6b7e6d67af0136
The show_models() function was not covered by any test so this
changeset is adding a new unit test for it.
Change-Id: Ia861f049c1f1ee0aa623404e62fb002392c9052d
In this changeset, I renamed watcher/doc.py file as
doc/ext/term.py which subsequently does not get scanned for coverage
anymore. Hence, we can close this bug.
Change-Id: I9d700da6569b464ce71085fe78002521555002b9
Closes-bug: #1527163
Service available group already exists.Therefore we don't need to
register this group here again.
Change-Id: I2096ed1f69a1f70fbf248fee5fded94e3caca6c6
Closes-Bug: #1621036
HasLength() based assertions are re-written to assertEqual() based
assertion to homogenize the test code base.
For example:
assertThat(.., HasLength()) becomes assertEqual(len(),...)
Change-Id: Ia3bf24e34fffe445ff4b0ee61fb7cbc0eb36a57a
Closes-Bug:#1629898
In tests/api/test_hooks.py
the 'test_hook_without_traceback_debug'
and 'test_hook_without_traceback_debug_tracebacks'
have the same function.
Change-Id: I5209bc8b1251b77b7444d51531c3902529d11453
As some of our utils function are actually available in oslo.utils,
this patchset simply gets rid of our local copy and instead references
the oslo.utils one. This will help us deport the code maintenance of
these to a 3rd party library.
Change-Id: I3760ebab69d35c37bbe78500918d4e46b5bd9119
GMR was ignoring the config because the conf wasn't passed when
starting any of the Watcher services. This changeset fixes this issue.
Change-Id: If386c5f0459c4278a2a56c8c3185fcdafce673a0
This adds a pip install command to tox.ini that is only used when the
tox env is passed with the 'constraints' factor appended onto it.
As such this will not effect developer workflows or current unit tests.
The initial use of this will be in a non-voting job, to verify that the
constrained checks with tox are stable. DevStack is already running
constrained jobs, as such problems are no expected.
To run a tox with pip using constraints on a developer system a
developer should run the desired tox environment with -constraints.
For example: $(tox -epy27-constraints)
Pip will pull the current version of the upper-constraints.txt file down
from the git.openstack.org, however this method can be overriden to use
a local file setting the environment variable "UPPER_CONSTRAINTS_FILE"
to the local path or a different URL, it is passed directly to pip.
This is currently not enabled in the default tox run, however it is
possible to enable it as a default by adding it to 'envlist' in tox.ini
This also removes requirements.txt from tox.ini deps
This is redundant, per lifeless email:
http://lists.openstack.org/pipermail/openstack-dev/2015-July/069663.html
Change-Id: I79c0ceb46fc980840a8baf5fa4a303bb450bfbec
cfg.CONF.debug should be set False as default,
If it's True, some unittests can't pass.
Change-Id: Ib098250af3aec48aa9d9152e20c80460f3bd641e
Closes-Bug: #1625560
I deactivated the watcher-dashboard plugin in the docs since it
doesn't at the moment. Will be reactivated once it gets fixed
(see https://bugs.launchpad.net/devstack/+bug/1540328).
Change-Id: I65de8ca4a08cdb294d0e48eac52927eed13ec66c
root.description = ("Watcher is an OpenStack project which aims to"
"to improve physical resources usage through"
Here more one 'to'
Change-Id: I3dac6cb15af43583a1360b7f2f14d4e2c9c26cf9
In this changeset, I fixed the issue with the basic server
consolidation strategy to now loop over all compute nodes
as expected instead of stopping after the first one.
Change-Id: If594f0df41e39dfb0ef8f0fce41822018490c4ec
Closes-bug: #1548874
ceilosca seems to not correctly handle group_by statement.
I remove it, because we don't need it for now.
Change-Id: Ie18551ba5a6bd155f9f4ae9c29c25b379affe019
Closes-Bug: #1623983
2016-09-15 17:16:38 +02:00
528 changed files with 33608 additions and 12140 deletions
An Audit Scope is a set of audited resources. Audit Scope should be defined
in each Audit Template (which contains the Audit settings).
.._audit_scope_definition:
Audit Template
==============
@@ -75,7 +83,7 @@ Audit Template
Availability Zone
=================
Please, read `the official OpenStack definition of an Availability Zone <http://docs.openstack.org/developer/nova/aggregates.html#availability-zones-azs>`_.
Please, read `the official OpenStack definition of an Availability Zone <https://docs.openstack.org/nova/latest/user/aggregates.html#availability-zones-azs>`_.
.._cluster_definition:
@@ -96,32 +104,19 @@ The :ref:`Cluster <cluster_definition>` may be divided in one or several
Replace the RABBIT_PASS with the password you chose for OpenStack user in RabbitMQ.
* In the `[keystone_authtoken]` section, configure Identity service access.
.. code-block:: ini
[keystone_authtoken]
...
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = watcher
password = WATCHER_PASS
Replace WATCHER_PASS with the password you chose for the watcher user in the Identity service.
* Watcher interacts with other OpenStack projects via project clients, in order to instantiate these
clients, Watcher requests new session from Identity service. In the `[watcher_clients_auth]` section,
configure the identity service access to interact with other OpenStack project clients.
.. code-block:: ini
[watcher_clients_auth]
...
auth_type = password
auth_url = http://controller:35357
username = watcher
password = WATCHER_PASS
project_domain_name = default
user_domain_name = default
project_name = service
Replace WATCHER_PASS with the password you chose for the watcher user in the Identity service.
* In the `[api]` section, configure host option.
.. code-block:: ini
[api]
...
host = controller
Replace controller with the IP address of the management network interface on your controller node, typically 10.0.0.11 for the first node in the example architecture.
* In the `[oslo_messaging_notifications]` section, configure the messaging driver.
.. code-block:: ini
[oslo_messaging_notifications]
...
driver = messagingv2
3. Populate watcher database:
..code-block:: ini
su -s /bin/sh -c "watcher-db-manage --config-file /etc/watcher/watcher.conf upgrade"
$ openstack optimize audit create -a at1 -p threshold=31.0
External Links
--------------
-`Intel Power Node Manager 3.0 <http://www.intel.com/content/www/us/en/power-management/intelligent-power-node-manager-3-0-specification.html>`_
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.