User story #9227
closedUser story #1808: Add an Audit mode to Rudder: only check properties, no modification on nodes
User story #7221: Set dry-run mode on each directive call
Generation must fail if a node has non compatible audit/enforce mode on multi-instance technique
Description
If a node has a multi-instance technique, with at least two directives where one is on policy mode = enforce and the other is on policy mode = audit, then we must fails the generation with explicit debuging information for the user.
We can't prevent that case to happen simply by UI guards, because there is a lot of cases where nobody actively set the mode to reach that state. For example, a node inventory makes a node belong to a new dynamic group, which brings the incompatible directive. Other example: a directive mode is changed from the API from a script (and we don't know at that moment that it will lead to incompatibilities on a node without massively impacting performance).
This is because for now, we only know how to set policy mode for a technique, not individual directives.
The alternatives, which are rejected, were:
- set the whole technique to "policy mode = enforce" (and find a way to warn the user that it is not what he chose to do): that means that things that MUST NOT CHANGE will certainly change, which is the worst thing we can do,
- set the whole technique to "policy mode = audit" (and find a way to warn the user that it is not what he chose to do): that is barelly better than the privious case, because it mean that if something should have been configured as a whole, some parts were let unchanged (think: package install), and most certainly the whole is broken.
- replace the directives by error reports or by an "abort" for that node (the idea being to let the node handle the case so that the generation is not broken globally for all nodes): we prefer to fails early (at generation time), so that big problems are not let ignored because nobody was looking at the right moment. The correct solution is to provide a by node generation of policies.
Updated by François ARMAND about 8 years ago
- Status changed from New to In progress
Updated by François ARMAND about 8 years ago
- Related to User story #7221: Set dry-run mode on each directive call added
Updated by François ARMAND about 8 years ago
- Status changed from In progress to Pending technical review
- Assignee changed from François ARMAND to Vincent MEMBRÉ
- Pull Request set to https://github.com/Normation/rudder/pull/1237
Updated by François ARMAND about 8 years ago
- Status changed from Pending technical review to Pending release
- % Done changed from 0 to 100
Applied in changeset rudder|3c4ecab20eb25782d12344eceeecdc4e14a2b937.
Updated by François ARMAND about 8 years ago
- Related to deleted (User story #7221: Set dry-run mode on each directive call)
Updated by Benoît PECCATTE about 8 years ago
- Target version changed from 4.0.0~rc2 to 318
Updated by Vincent MEMBRÉ about 8 years ago
- Target version changed from 318 to 4.0.0~rc2
Updated by Vincent MEMBRÉ about 8 years ago
- Target version changed from 4.0.0~rc2 to 4.0.0~rc1
Updated by Alexis Mousset about 8 years ago
- Status changed from Pending release to Released
This bug has been fixed in Rudder 4.0.0 which was released the 10th November 2016.