The "single point of failure" is the entire application inclusive of all of its worker-bees, and the "failure" that can occur is that any or all of those "bees" misbehave. Therefore, focus simply on the strongest possible design. In this case, have one process or thread whose only purpose is to recognize that a new file has arrived. Let that process/thread add an entry to a "work-to-do" queue, which is read by all of the "bees." Now, those "bees" never have to worry about interference. Let all of the processes, including both the bees and the directory-watcher, be owned by a parent-process whose only purpose in life is to make sure that none of its children die.

In reply to Re: Synchronizing multiple processes retrieving files out of shared directory by Anonymous Monk
in thread Synchronizing multiple processes retrieving files out of shared directory by MitchInOmaha

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.