By: Jörg Thalheim <joerg@thalheim.io>
server,client: record uploads at completion with real refs and size Register objects with the refs and size from their pending_objects row instead of empty refs and unknown size, so object_stats stays accurate. Fail the multipart completion request if registration fails, before the tracking row is dropped, so a client retry can re-attempt the idempotent insert. Add POST /api/uploads/complete so presigned (non-multipart) uploads -- narinfos, listings, build logs, realisations, small NARs -- are also recorded when they finish. Otherwise a closure that never commits leaves them unknown to the objects table and every later closure re-uploads them. The client notifies the server best-effort after each presigned PUT.
| Time to Start | Worker time | Duration | Time to finish | Idle | |
| Config | 14s | 2s | 2s | 17s | 14s |
| Eval | 35s | 23s | 23s | 58s | 18s |
| Build | - | - | - | - | 6m31s |
| Suite | 14s | 25s | - | - | 7m04s |