CASQueueFile writes its header to a a temporary commitFile with comments suggesting it should try and recover from failure when updating the metadata header.
This logic does not exist in the Java implementation of tape.
Worse yet, the Objective-C implementation does not actually recover from failure; it silently discards the queue file entirely and pretends like the queue was empty.
Probably this logic should just be deleted. Either we assume the OS writes the header atomically (in which case we don't need the temporary commitFile), or we need to write the entire queue (header and data) to a temporary file, then rename the temporary file over the real file.