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

Use require_relative in puppet

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: PUP 7.7.0
    • Component/s: None
    • Labels:
    • Template:
    • Team:
      Coremunity
    • Sprint:
      Platform Core KANBAN
    • Release Notes:
      Enhancement
    • Release Notes Summary:
      Converts puppet to use `require_relative` eliminating about 5000 file system calls when loading puppet. This accounts for between 5 to 15% of the total number of file system calls for different platforms.
    • QA Risk Assessment:
      Needs Assessment

      Description

      Update puppet to use require_relative in cases where we know the file to load is in the same repo. This can't be used in cases where extensions may be loaded from modules, such as features, etc.

      There are reports require_relative misbehaves on some versions of JRuby https://github.com/jruby/jruby/issues/5618

      So we may need to implement something like what rspec did: https://github.com/rspec/rspec-support/blob/4ad8392d0787a66f9c351d9cf6c7618e18b3d0f2/lib/rspec/support.rb#L14-L31

        Attachments

          Activity

            People

            Assignee:
            josh Josh Cooper
            Reporter:
            josh Josh Cooper
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Zendesk Support