[Task-based] Task serializer should cut the self dependencies in cross-node fields

Bug #1547889 reported by Alexey Shtokolov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Committed
High
Bulat Gaifullin

Bug Description

When we deploy all nodes simultaneously we need to setup some services on primary-controller prior to secondaries.
Now we have to split controllers tasks onto two parts: primary-task and task (on secondary controllers). It leads to multiple misunderstandings.

We can fix it, if we use only one task for all controllers with cross-deps: task on primary-controller.
So we need to prevent the self dependencies during the tasks serialisation.

summary: - [Task-based] Task serializer should brake the self dependencies in
- cross-node fields
+ [Task-based] Task serializer should cut the self dependencies in cross-
+ node fields
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-web (master)

Fix proposed to branch: master
Review: https://review.openstack.org/291119

Changed in fuel:
assignee: Bulat Gaifullin (bgaifullin) → Vladimir Kuklin (vkuklin)
status: Confirmed → In Progress
Changed in fuel:
assignee: Vladimir Kuklin (vkuklin) → Bulat Gaifullin (bgaifullin)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-web (master)

Reviewed: https://review.openstack.org/291119
Committed: https://git.openstack.org/cgit/openstack/fuel-web/commit/?id=68c4379e2c07bf284d952193a75401ec59365bfe
Submitter: Jenkins
Branch: master

commit 68c4379e2c07bf284d952193a75401ec59365bfe
Author: Vladimir Kuklin <email address hidden>
Date: Mon Mar 14 19:45:24 2016 +0300

    Make Nailgun cut self referring cross-dependencies loops

    This commit introduces an additional check on whether
    a cross-dependency resolves to the same task on the same
    node. This is very handy and allows a deployment engineer
    to keep the same task name and create a sequence of execution
    for it, e.g.:
    make database deploy on primary controller first

    database:
      ...
      groups: [primary-controller, controller]
      cross-depends:
        name: database
        role: primary-controller
      ...

    instead of

    primary-database:
      ...
      groups: [primary-controller]
      ...

    database:
      groups: [controller]
      cross-depends:
        name: primary-database

    But this might introduce a loop where task depends
    on itself on the same node.

    The commit below introduces an additional condition for this
    to not yield such looping dependencies when they are met.

    This behaviour is not triggered for cross-dependencies referring to
    role:self as they are essentially an extension of required and
    required_for varinats with support of regular expressions.

    This commit also fixes some tests that had such loops defined in unit
    tests, thus failing with this new condition enabled.

    Change-Id: I6aea7cc75bc9fa2c512083ff776a831137b6e220
    Closes-bug: #1547889

Changed in fuel:
status: In Progress → Fix Committed
tags: added: on-verification
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.