Support for systems with many external drives

It seems that several beta users have a bunch (5+) external drives and remote filesystems mounted on their machines that run PhotoStructure.

Currently, PhotoStructure (even v1.0.0-beta.2) collects all mounted volume metadata. This collection can take a while, which led to posts like this.

I just had a user ask:

why the heck does photostructure care about any of my other drives?

and this is absolutely a fair question!

Volume metadata extraction is expensive, so PhotoStructure actually only collects volume metadata in the “main” process. All child processes (sync, sync-file, and web) all use RPC to get the cached volumes() result from main.

Computing stable URIs for files requires a volume UUID for every mountpoint: and main doesn’t know what path the child processes are interested in, so it fetches them all.

PhotoStructure | What's a “drive,” or “volume?” has details about these shenanigans: but it means you can mount a specific external drive to multiple drive letters, even on different computers, and your library will figure out that it’s a drive it’s already imported (rather than duplicating all the asset files).

I just realized I could rewrite the volume handling code to lazy-fetch just the related mountpoint, though. This feature will track that work.