We are satisfied to announce the release of: watcher 15.0.0 This release is part of the flamingo release series. The source is available from: https://opendev.org/openstack/watcher Download the package from: https://tarballs.openstack.org/watcher/ Please report issues through: https://bugs.launchpad.net/watcher/+bugs For more details, please see below. Changes in watcher 14.0.0..15.0.0 --------------------------------- fe56660c Handle missing dst_pool parameter in zone_migration 6cb4e2fa Enable storage model collector by default 9b1adaa7 Add 2025.2 release notes prelude f21df7ce Update prometheus-threading parent jop 90009aac Check result of retype action based on type and status a4b785e4 Fix doc section to enable cinder notifications ef0f3519 Make Monasca client optional and lazy-load c9bfb763 Allow status_message updates for actions in SKIPPED state eb3fdb1e Update aetos fake data job to disable real metrics 7106a122 Rename confusing query timeout options 03c09825 Extend compute model attributes 2452c1e5 Follow up changes for skip-action blueprint 1a87abc6 Fix missing watcher_workflow_engines.taskflow section a07bfa14 Fix type mismatch between option and its default 45781907 Update Overload standard deviation doc cc26b3b3 Add options to disable migration in host maintenance 9003906b Fix NovaHelper microversion comparison e06f1b04 API changes for skipped actions: patch actions and status_message 6d35be11 Skip actions automatically based on pre_condition results 1009c378 Validate endpoint_type option at loading 5048a6e3 Add `status_message` to objects and notifications 84742be8 Add `status_message` column to Actions, Audits and ActionPlans tables 1fb89aea Add parameters to force failures in nop action 1a9f1774 Add patch call validation based on allowed_attrs 3742e0a7 use cinder migrate for swap volume 8309d984 Add Aetos datasource 9becb684 Add new tests to validate GET /infra-optim/v1/data_model 37faf614 Fix api-ref doc for GET /infra-optim/v1/data_model 8ca794cd Add a new tox environment to run unit tests in threading mode f879b10b Extend decision engine to support threading mode 95d975f3 Replace dateutils usage with datetime and oslo.utils 0435200f Disable real metrics on devstack injected data jobs adfe3858 Configure watcher tempest's microversion in devstack 3e8392b8 finalize python 3.9 support removal 20cd4a03 Add comprehensive release liaison guide for DPL model 2fe3b0cd Fix release notes typo and extra information 081cd5fa Merge decision engine services into a single one e3b813e2 Drop Code related to OperationNotPermitted exception c0a5abe2 Drops forbidden patch/delete/post action apis 828bcadf sqlalchemy: Use built-in declarative aa67096f Drop unused fake class 6f72e33d Add crosslinks to strategies table 56d0a0d6 Update workload balance doc per review comments de9eb2cd Add doc clarifications for Zone Migration bfbd136f Update Host Maintenance strategy documentation 6ea362da Use KiB as unit for host_ram_usage when using prometheus datasource 1529e3fa Add debug message to report calculated metric for workload_balance 0599618a Add table - level of test/usage per strategy 3860de0b Aggregate by label when querying instance cpu usage in prometheus 15981117 Drop unused method get_disabled_compute_nodes_with_reason 4f8c1464 Move eventlet command scripts to a different dir 520ec0b7 Add warning message for experimental integrations f42cb855 Update Workload Balance strategy documentation b788a67c Add Integrations doc page with support matrix bf6a28bd Fix audit creation with no name and no goal or audit_template 1256b241 Adapt zuul.yaml strategies jobs to include tests with tag 'strategy' a559c050 devstack: Drop template for mod_wsgi 88d81c10 Set actionplan state to FAILED if any action has failed 167fb61b Add unit test zone migration with_attached_volume 188e583d Drop sg_core related prometheus var a016b3f4 add missing bindeps for docs 9f6c8725 resolve fixme comments in RequestContext 040a7f5c update tests for new oslo.context release c6302ede Handle missing dst_node parameter in zone_migration 0651fff9 Added unit test to validate audit creation with no goal and no name b36ba839 Add unit test to check action plan state when a nested action fails 4629402f Return HTTP code 400 when creating an audit with wrong parameters 63626d6f Add test for missing destination in zone migration 0f5b6a07 Fix incorrect logging format 7d90a079 Check logs in some cinder and nova helper tests 89111947 Add a unit test to check the error when creating an audit with wrong parameters 9dea55bd Drop code from Host maintenance strategy migrating instance to disabled hosts b4ef969e Remove deprecated executor in message handling servers 322c89d9 Migrate value column of efficacy indicator on load 3f6c7e40 Drop nova command reference from the code 17d1cf53 Deprecated Noisy Neighbor strategy ae48f65f Set keystone_client default interface to public 0ed3d4de Set number of decimal digits in efficacy indicator 6c584572 Add test for EfficacyIndicator value in mysql 77e7e4ef drop jammy jobs f38ab70b drop suse supprot in the devstack plugin 7aabd6dd update pre-commit hook versions 57b248f9 Add support for pyproject.toml and wsgi module paths 278cb7e9 [host_maintenance] Pass des hostname in add_action solution 2c76da28 Make prometheus the default devstack example c4acce91 Add real-data based tests to experimental and weekly pipelines 0702cb38 Drop sg_core prometheus related vars c7158b08 Aggregate by fqdn label instead instance in host cpu metrics 253e9767 Replace watcherclient functional job with python-watcherclient-functional c7bb1fe5 Imported Translations from Zanata a65e7e9b Query by fqdn_label instead of instance for host metrics b671550c Update master for stable/2025.1 539be503 Do not collect node_exporter cpu metrics in prometheus job Diffstat (except docs and test files) ------------------------------------- .pre-commit-config.yaml | 8 +- .zuul.yaml | 219 +++++-- api-ref/source/parameters.yaml | 93 ++- .../samples/action-skip-request-with-message.json | 12 + api-ref/source/samples/action-skip-request.json | 7 + api-ref/source/samples/action-skip-response.json | 29 + .../action-update-status-message-request.json | 7 + .../action-update-status-message-response.json | 29 + .../samples/actionplan-list-detailed-response.json | 3 +- .../source/samples/actionplan-show-response.json | 5 +- .../samples/actions-list-detailed-response.json | 5 +- api-ref/source/samples/actions-show-response.json | 5 +- api-ref/source/samples/audit-create-response.json | 3 +- .../samples/audit-list-detailed-response.json | 3 +- api-ref/source/samples/audit-show-response.json | 3 +- .../source/samples/datamodel-list-response.json | 56 +- api-ref/source/watcher-api-v1-actionplans.inc | 3 + api-ref/source/watcher-api-v1-actions.inc | 107 ++++ api-ref/source/watcher-api-v1-audits.inc | 5 + api-ref/source/watcher-api-v1-datamodel.inc | 27 +- bindep.txt | 23 + devstack/files/apache-watcher-api.template | 42 -- devstack/lib/watcher | 105 +--- devstack/local.conf.compute | 6 +- devstack/local.conf.controller | 49 +- devstack/local_gnocchi.conf.compute | 53 ++ devstack/local_gnocchi.conf.controller | 57 ++ devstack/plugin.sh | 3 + devstack/prometheus.yml | 16 + .../action-execution-error.json | 2 + .../action-execution-start.json | 2 + .../action_plan-cancel-end.json | 2 + .../action_plan-cancel-error.json | 4 +- .../action_plan-cancel-start.json | 2 + .../action_plan-execution-end.json | 2 + .../action_plan-execution-error.json | 6 +- .../action_plan-execution-start.json | 2 + .../image_src/plantuml/action_state_machine.txt | 23 + pyproject.toml | 3 + .../notes/2025.2-prelude-a9f4c7b2e8d15692.yaml | 23 + .../add-fail-options-to-nop-f44f506dc732f2a1.yaml | 14 + .../add-wsgi-module-support-597f479e31979270.yaml | 30 + .../notes/aetos-datasource-60e50a2338c64c08.yaml | 13 + ...lueprint-add-skip-actions-4a5a997dc1133f13.yaml | 20 + ...-compute-model-attributes-b56bc093e8637bb4.yaml | 14 + ...ries-with-multiple-target-0e65d20711d1abe2.yaml | 8 + .../notes/bug-2109494-e5bf401767fa6cd6.yaml | 11 + releasenotes/notes/bug-2110947.yaml | 10 + .../notes/bug-2112100-c1e56173cd29a35e.yaml | 11 + .../notes/bug-2112187-763bae283e0b736d.yaml | 47 ++ .../notes/bug-2113776-4bd314fb46623fbc.yaml | 14 + ...26-fix-model-list-api-ref-30cc7ed1c85c0d0e.yaml | 7 + ...x-nova-microversion-check-9022a378b75d046f.yaml | 7 + ...-updates-in-skipped-state-a8b4c5d7e9f2g3h1.yaml | 11 + ...ion-engine-threading-mode-26fc8066dcd499a2.yaml | 12 + ...cate-noisy-neighbor-strat-7da910837ae8fa80.yaml | 6 + ...trategy-on-disabled-hosts-24084a22d4c8f914.yaml | 10 + ...n-not-permitted-exception-14e49b35a3ca00d1.yaml | 6 + ...ch-delete-post-action-api-37fe4ce5be6500db.yaml | 6 + releasenotes/notes/drop-py39-8a9c99678b3e8eeb.yaml | 6 + ...teutil-dependency-2118404-f5a8b2c1e9d4a6b3.yaml | 5 + ...experimental-integrations-490d4cc32444288d.yaml | 6 + ...ion-plan-state-on-failure-69e498d902ada5c5.yaml | 13 + ...disable-migration-options-a2b72e32736e5446.yaml | 17 + ...e-monasca-client-optional-7e1a96b2ac902867.yaml | 13 + ...nterval-not-query-timeout-ecb6f2c6b1a647e9.yaml | 21 + ...ror-400-on-bad-parameters-bb964e4f5cadc15c.yaml | 7 + ...age_model_enabled_default-48c197f5a540956c.yaml | 7 + ...pdate-notification-topics-daf6303a63963ee9.yaml | 7 + ...tablization-strategy-name-9988e554ac2655a2.yaml | 7 + ...igration-missing-dst-node-bd0377af1f1ed245.yaml | 14 + releasenotes/source/2025.1.rst | 6 + releasenotes/source/index.rst | 1 + .../source/locale/fr/LC_MESSAGES/releasenotes.po | 33 + requirements.txt | 6 +- setup.cfg | 16 +- test-requirements.txt | 4 + tools/test-setup.sh | 56 ++ tox.ini | 23 +- .../api/controllers/rest_api_version_history.rst | 9 + watcher/api/controllers/v1/action.py | 145 +++-- watcher/api/controllers/v1/action_plan.py | 22 +- watcher/api/controllers/v1/audit.py | 62 +- watcher/api/controllers/v1/audit_template.py | 15 +- watcher/api/controllers/v1/data_model.py | 23 +- watcher/api/controllers/v1/goal.py | 7 - watcher/api/controllers/v1/scoring_engine.py | 8 - watcher/api/controllers/v1/service.py | 7 - watcher/api/controllers/v1/strategy.py | 7 - watcher/api/controllers/v1/types.py | 11 + watcher/api/controllers/v1/utils.py | 19 + watcher/api/controllers/v1/versions.py | 4 +- watcher/applier/action_plan/default.py | 31 +- .../applier/actions/change_nova_service_state.py | 6 +- watcher/applier/actions/migration.py | 4 +- watcher/applier/actions/nop.py | 32 +- watcher/applier/actions/stop.py | 169 +++++ watcher/applier/actions/volume_migration.py | 98 +-- watcher/applier/workflow_engine/base.py | 72 ++- watcher/applier/workflow_engine/default.py | 5 +- watcher/cmd/__init__.py | 29 - watcher/cmd/eventlet/__init__.py | 36 ++ watcher/cmd/{ => eventlet}/api.py | 0 watcher/cmd/{ => eventlet}/applier.py | 0 watcher/cmd/{ => eventlet}/decisionengine.py | 9 +- watcher/common/cinder_helper.py | 52 +- watcher/common/clients.py | 46 +- watcher/common/context.py | 42 +- watcher/common/exception.py | 13 +- watcher/common/executor.py | 51 ++ watcher/common/keystone_helper.py | 45 +- watcher/common/nova_helper.py | 47 +- watcher/common/oslo_service_helper.py | 33 + watcher/common/placement_helper.py | 2 +- watcher/common/policies/action.py | 11 + watcher/common/rpc.py | 2 - watcher/common/scheduling.py | 33 +- watcher/common/utils.py | 8 +- watcher/conf/__init__.py | 4 + watcher/conf/aetos_client.py | 50 ++ watcher/conf/cinder_client.py | 6 +- watcher/conf/collector.py | 17 +- watcher/conf/datasources.py | 16 +- watcher/conf/decision_engine.py | 3 +- watcher/conf/glance_client.py | 6 +- watcher/conf/gnocchi_client.py | 6 +- watcher/conf/ironic_client.py | 8 +- watcher/conf/keystone_client.py | 2 +- watcher/conf/models.py | 40 ++ watcher/conf/monasca_client.py | 6 +- watcher/conf/neutron_client.py | 6 +- watcher/conf/nova_client.py | 6 +- watcher/db/sqlalchemy/alembic/env.py | 6 - ...375ca737_change_efficiacy_indicator_decimals.py | 20 + ...150a7d8f228_add_status_message_to_actionplan.py | 20 + watcher/db/sqlalchemy/api.py | 49 +- watcher/db/sqlalchemy/models.py | 9 +- watcher/decision_engine/audit/continuous.py | 4 +- watcher/decision_engine/datasources/aetos.py | 67 ++ watcher/decision_engine/datasources/base.py | 8 +- watcher/decision_engine/datasources/manager.py | 44 +- watcher/decision_engine/datasources/monasca.py | 19 +- watcher/decision_engine/datasources/prometheus.py | 424 +------------ .../decision_engine/datasources/prometheus_base.py | 480 ++++++++++++++ .../decision_engine/messaging/audit_endpoint.py | 10 +- watcher/decision_engine/model/collector/base.py | 10 +- watcher/decision_engine/model/collector/manager.py | 25 +- watcher/decision_engine/model/collector/nova.py | 21 +- watcher/decision_engine/model/element/instance.py | 3 + watcher/decision_engine/model/model_root.py | 15 + watcher/decision_engine/model/notification/nova.py | 16 +- watcher/decision_engine/planner/weight.py | 2 + watcher/decision_engine/service.py | 68 ++ .../decision_engine/strategy/strategies/base.py | 2 +- .../strategy/strategies/host_maintenance.py | 108 ++-- .../strategy/strategies/noisy_neighbor.py | 6 + .../strategy/strategies/workload_balance.py | 48 +- .../strategy/strategies/workload_stabilization.py | 16 +- .../strategy/strategies/zone_migration.py | 81 +-- watcher/decision_engine/threading.py | 7 +- watcher/eventlet.py | 17 +- watcher/locale/de/LC_MESSAGES/watcher.po | 6 +- watcher/locale/en_GB/LC_MESSAGES/watcher.po | 9 +- watcher/notifications/action.py | 31 +- watcher/notifications/action_plan.py | 34 +- watcher/notifications/audit.py | 33 +- watcher/objects/action.py | 5 +- watcher/objects/action_plan.py | 6 +- watcher/objects/audit.py | 5 +- .../action_plan/test_default_action_handler.py | 95 +++ .../test_default_workflow_engine.py | 282 +++++++++ .../test_taskflow_action_container.py | 118 +++- .../decision_engine/cluster/test_nova_cdmc.py | 75 ++- .../datasources/test_aetos_helper.py | 61 ++ .../decision_engine/datasources/test_manager.py | 114 +++- .../datasources/test_monasca_helper.py | 11 +- .../datasources/test_prometheus_base.py | 690 +++++++++++++++++++++ .../datasources/test_prometheus_helper.py | 607 ++---------------- .../data/scenario_11_with_1_node_no_instance.xml | 5 + .../data/scenario_11_with_2_nodes_2_instances.xml | 10 + .../model/faker_cluster_and_metrics.py | 6 - .../decision_engine/model/faker_cluster_state.py | 6 + .../notification/data/instance-update-2-1.json | 90 +++ .../model/notification/test_nova_notifications.py | 75 ++- .../decision_engine/planner/test_weight_planner.py | 16 +- .../strategy/strategies/test_base.py | 29 +- .../strategy/strategies/test_host_maintenance.py | 455 +++++++++++++- .../strategy/strategies/test_workload_balance.py | 42 +- .../strategies/test_workload_stabilization.py | 62 +- .../strategy/strategies/test_zone_migration.py | 108 +++- .../notifications/test_action_notification.py | 86 ++- .../notifications/test_action_plan_notification.py | 64 +- watcher/wsgi/__init__.py | 0 watcher/wsgi/api.py | 18 + 270 files changed, 9312 insertions(+), 2331 deletions(-) Requirements updates -------------------- diff --git a/requirements.txt b/requirements.txt index ae53ed09..5d69fcc7 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,0 +5 @@ apscheduler>=3.5.1 # MIT License +debtcollector>=1.2.0 # Apache-2.0 @@ -24 +25 @@ oslo.serialization>=2.25.0 # Apache-2.0 -oslo.service>=1.30.0 # Apache-2.0 +oslo.service[threading]>=4.2.1 # Apache-2.0 @@ -36 +36,0 @@ python-keystoneclient>=3.15.0 # Apache-2.0 -python-monascaclient>=1.12.0 # Apache-2.0 @@ -39 +39 @@ python-novaclient>=14.1.0 # Apache-2.0 -python-observabilityclient>=0.3.0 # Apache-2.0 +python-observabilityclient>=1.1.0 # Apache-2.0 diff --git a/test-requirements.txt b/test-requirements.txt index 4b261e60..f668bcc0 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,0 +2 @@ coverage>=4.5.1 # Apache-2.0 +ddt>=1.2.1 # MIT @@ -7,0 +9,3 @@ WebTest>=2.0.27 # MIT + +# Include drivers for opportunistic testing. +oslo.db[mysql]>=6.0.0 # Apache-2.0