HomePhorge

parser/files: use a cheaper test for "is this path absolute?"
58f6ca19c0deUnpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

parser/files: use a cheaper test for "is this path absolute?"

The parser used path == File.expand_path(path) as a test for the path being
absolute - something that wasn't entirely accurate, and that also wasn't
terrible fast. It also generated substantial memory and object allocation
traffic in the VM.

Replacing that with our util absolute_path? tool is faster and more efficient.

Signed-off-by: Daniel Pittman <daniel@puppetlabs.com>

Details

Provenance
Daniel Pittman <daniel@puppetlabs.com>Authored on
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPU275c94d7cb2a: Eliminate remaining uses of FileCollection.
Branches
Unknown
Tags
Unknown

Event Timeline

Daniel Pittman <daniel@puppetlabs.com> committed rPU58f6ca19c0de: parser/files: use a cheaper test for "is this path absolute?" (authored by Daniel Pittman <daniel@puppetlabs.com>).Sep 18 2012, 3:07 AM