HomePhorge

[#4771] Import of manifests with the same name only happens once
2b50f30c703aUnpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

[#4771] Import of manifests with the same name only happens once

The function import_if_possible, which was supposed to be responsible
for making sure that no two threads tried to import the same file at
the same time, was not making this decision based on the full pathname
of the file, since it was being invoked before pathnames were
resolved. As a result, if we attempted to import two distinct files
with the same name at the same time (either in two threads or in a
single thread due to recursion), one of the files would not always get
imported.

Fixed this problem by moving the thread-safety logic to happen after
filenames are resolved to absolute paths. This made it possible to
simplify the thread-safety logic significantly.

Details

Provenance
Paul Berry <paul@puppetlabs.com>Authored on
James Turnbull <james@lovedthanlost.net>Committed on Sep 23 2010, 1:21 AM
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPU7b8cb741596c: Fix for #4708 - tagmail should allow . in tagname
Branches
Unknown
Tags
Unknown

Event Timeline

James Turnbull <james@lovedthanlost.net> committed rPU2b50f30c703a: [#4771] Import of manifests with the same name only happens once (authored by Paul Berry <paul@puppetlabs.com>).Sep 23 2010, 1:21 AM