Uploaded image for project: 'CFEngine Community'
  1. CFEngine Community
  2. CFE-242

overloaded cf_promises_validated or validated_<input> with -f <input> timestamp use

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: (None)
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: cf-execd
    • Labels:
      None

      Description

      Agent use of cf_promises_validated as parsed time causes conflicts for workdirs with any other component running which can update the global validated mechanism. My canonical example is cf-execd running with cf-serverd, very likely with policy server.

      1. With both cf-execd and cf-serverd running with default input of 'promises.cf'
      2. touch/modify promises.cf in inputs directory
      3. (Very likely) cf-serverd will see this change, rerun cf-promises and update workdir cf_promises_validated
      4. cf-execd calls NewPromiseProposals, which interprets cf_promises_validated mtime blindly as "the last time inputs were parsed".
      5. The touched/modified promises.cf is never parsed.

      I suggest that cf_promises_validated's mtime not be used by cf-execd, or at least not populate PROMISETIME with its mtime.
      Pull request filed as https://github.com/cfengine/core/pull/259

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            werkt George Gensure
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: