Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-3893

refresh events logged for resources that don't match tags

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Template:

      Description

      When using tags to restrict resources that notify other resources, the refresh event appears in the logs. See the example below where a File notifies a Service:

      <pre>
      file

      { '/tmp/foo': ensure => present, tag => [ 'woof', 'cow' ], }

      service

      { 'foo': ensure => running, tag => [ 'woof', 'cow' ], }

      file

      { '/tmp/bar': ensure => present, notify => Service['foo'], }

      $ puppet apply test.pp --tags file --noop
      Notice: /Stage[main]//File[/tmp/foo]/ensure: current_value absent, should be present (noop)
      Notice: /Stage[main]//File[/tmp/bar]/ensure: current_value absent, should be present (noop)
      Notice: /Stage[main]//Service[foo]: Would have triggered 'refresh' from 1 events
      Notice: Class[Main]: Would have triggered 'refresh' from 3 events
      Notice: Stage[main]: Would have triggered 'refresh' from 1 events
      </pre<

      Service[foo] is not actioned upon because it does not have a matching tag, however we still get a log message about it. This could be misinterpreted in to thinking that Service[foo] would be restarted.

      The log message probably comes from the File resource that "sends" the refresh event, up to you whether you think it's worth squashing or not as it would be a very slight change in behaviour.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                redmine.exporter redmine.exporter
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Zendesk Support