Project

General

Profile

Actions

Architecture #7580

closed

Remove unused tracking variable in distributePolicy

Added by François ARMAND over 8 years ago. Updated over 8 years ago.

Status:
Released
Priority:
2
Category:
System techniques
Target version:
Effort required:
Name check:
Fix check:
Regression:

Description

In distributePolicy/1.0 -> metadata.xml, we have:

  <TRACKINGVARIABLE>
    <SAMESIZEAS>CMDBENDPOINT</SAMESIZEAS>
  </TRACKINGVARIABLE>

Which is VERY strange.

It does not seems to have the least impact on generated code, so at best, it is dead code, at worst a bug.

We should remove it 3.2, but let it in previous release in the case it is somehow used.

Actions #1

Updated by Janos Mattyasovszky over 8 years ago

yeah I already wanted to ask about that...
the technique foswiki-entry http://www.rudder-project.org/foswiki/Development/TechniqueXML says Optional; defines the cardinality of this variable based on the cardinality of the VariableName, but I don't know what this is supposed to mean :-)

Actions #2

Updated by François ARMAND over 8 years ago

@Janos Matya: this a complexe feature, a reminiscence from the past, that should never have been done like that. The need is to be able to link to multivalued variable so that you can iter on there elements together, even when the arity of the two don't matches and so you need to do some flattening on one (typical example: I have a list of elements with sub elements, and I need to access the parent when processing a children).

Basically, what you need to know is: don't do that. Use templates. Or CFEngine arrays.

Actions #3

Updated by François ARMAND over 8 years ago

  • Status changed from New to In progress
  • Assignee changed from Nicolas CHARLES to François ARMAND
Actions #4

Updated by François ARMAND over 8 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from François ARMAND to Nicolas CHARLES
  • Pull Request set to https://github.com/Normation/rudder-techniques/pull/816
Actions #5

Updated by François ARMAND over 8 years ago

  • Status changed from Pending technical review to Pending release
  • % Done changed from 0 to 100
Actions #7

Updated by Alexis Mousset over 8 years ago

  • Subject changed from remove unused tracking variable in distributePolicy to Remove unused tracking variable in distributePolicy
Actions #8

Updated by Benoît PECCATTE over 8 years ago

  • Status changed from Pending release to Released
Actions

Also available in: Atom PDF