Common Failure Modes and Operational Edge Cases
Clock Skew Failures
Presigned URLs embed generation and expiration timestamps. If the signing server clock differs from storage service clock, URLs fail unpredictably. A server running 2 minutes ahead generates URLs that appear expired immediately. Symptoms include intermittent signature expired errors correlating with which server handled the request. Fix requires NTP synchronization on all signing servers with monitoring for clock drift. Alert if any server drifts beyond 5 seconds.
Credential Rotation Chaos
When signing credentials rotate, outstanding presigned URLs can break. At 10:00 AM, key A signs a URL valid until 10:15 AM. At 10:05 AM, key A rotates to key B. The URL is still time valid but key A no longer exists. URL fails with invalid access key. Mitigation: keep old credentials active during transition. If URLs can be valid for 1 hour, old credentials must remain valid for 1 hour after rotation.
URL Caching Bugs
Caching pages containing presigned URLs causes failures when URLs expire. Common mistake: CDN caches page HTML for 1 hour, presigned URLs expire in 15 minutes. Users visiting cached page get broken URLs. Solutions: URL expiration must exceed page cache duration, pages must be uncached, or URLs must be fetched client side via API.
Large File Upload Timeout
A presigned URL might expire during slow upload. User on poor connection requests URL valid 15 minutes, upload takes 20 minutes, fails partway. For large uploads, use multipart presigned URLs. Each part gets its own URL and completes quickly. Overall upload can span hours across sessions.