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

Applying catalogs spends an inordinate amount of time checking for failed dependencies.

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • PUP 4.0.0
    • PUP 4.2.0
    • Catalog Application
    • None
    • 1
    • Client 2015-06-10
    • New Feature

    Description

      I profiled `puppet agent --test` on one of my servers using stackprof [1] on Ruby 2.1.

      Something like 30% or more of the time was spent in `Puppet::Graph::SimpleGraph#upstream_from_vertex`, called from `Puppet::Transaction#failed_dependencies?`

      It turns out that, while evaluating the resource graph, when considering a resource, we look at the complete set of transitive dependencies to evaluate whether any of them have failed. This is hugely expensive, and moreover, is completely wasted work in the success case where no resources have failures.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              nelhage Nelson Elhage
              Eric Thompson Eric Thompson
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Zendesk Support