trunc is here, but it also seems to ignore the case of non-sequential i/o right now. For example, in a large upload, with the size already set high, a bunch of aio_writes() at the end could complete before ones at the beginning, and another process or thread reading the object at that point would get errors from -ENOENT on the early objects.

If the size isn't set before hand, a bunch of aio_writes completing at the end, crashing, and failing to complete the earlier writes or update the size, finding the all written objects with a linear scan doesn't have a good bound to stop looking.