Grand Central Strategy for Opening Multiple Files

Posted by user276632 on Stack Overflow See other posts from Stack Overflow or by user276632
Published on 2010-12-26T02:23:53Z Indexed on 2010/12/26 2:54 UTC
Read the original article Hit count: 285

I have a working implementation using Grand Central dispatch queues that (1) opens a file and computes an OpenSSL DSA hash on "queue1", (2) writing out the hash to a new "side car" file for later verification on "queue2".

I would like to open multiple files at the same time, but based on some logic that doesn't "choke" the OS by having 100s of files open and exceeding the hard drive's sustainable output. Photo browsing applications such as iPhoto or Aperture seem to open multiple files and display them, so I'm assuming this can be done.

I'm assuming the biggest limitation will be disk I/O, as the application can (in theory) read and write multiple files simultaneously.

Any suggestions?

TIA

© Stack Overflow or respective owner

Related posts about objective-c

Related posts about c