Repository navigation
Description
When syncing — in either direction — a transient rate-limit response ({"error":"Too many requests"}) from the auth server's .well-known/openid-configuration endpoint causes JobQueue::clear() to fire, aborting all pending jobs regardless of type: GETFileJob (downloads), SimpleNetworkJob / POST (uploads), and TUS transfers. Running jobs are critically deleted. The sync engine declares the run complete, so aborted files are never retried and the client shows no error. Quitting and restarting repeatedly eventually works through the backlog, but it takes many cycles.
Reproduced on two different Macs (MBP M1 Max and Mac Mini M4), both running client 3.0.3.2073 against OpenCloud 7.1.0. On the MBP, four consecutive log segments (spanning ~3 minutes of restarts) each show the identical failure: upload jobs aborted by the same rate-limit cascade. The Mini captured the download-side failure cleanly.
Steps to Reproduce
- Create a space with several hundred files across nested directories
- Connect a macOS desktop client (3.0.3.2073) to sync that space, HTTP logging enabled
- Observe discovery + reconciliation complete normally, jobs queued
- A
.well-known/openid-configurationfetch returns{"error":"Too many requests"} JobQueue::clear()aborts all pending jobs —POST(uploads),GET(downloads), and running jobs- Client shows no error; directories exist but files are missing; subsequent syncs skip already-"synced" items
MBP Upload Failures (4 consecutive restarts, each aborted)
11:53:51 JobQueue::clear → Abort SimpleNetworkJob ×21 (POST uploads) + 12 critical deletions
11:54:33 JobQueue::clear → Abort SimpleNetworkJob ×21 (POST uploads) + 10 critical deletions
11:55:05 JobQueue::clear → Abort SimpleNetworkJob ×22 (POST uploads)
11:55:32 JobQueue::clear → Abort SimpleNetworkJob ×21 (POST uploads) + 3 critical deletions
Mini Download Failure (initial sync)
11:59:08 .well-known → {"error":"Too many requests"} → JobQueue::clear
Abort GETFileJob ×20 + Deleting running job ×5
Result: 88/100s of files synced, directories empty
Environment
- macOS 26.4.1 (Mac Mini) / 25.5.0 (MBP), client 3.0.3.2073
- OpenCloud 7.1.0 behind Caddy, HTTP/2 enabled
- Pocket ID (OIDC) auth at separate auth server
Workaround
Quitting and restarting the client repeatedly eventually works through the sync backlog, as each cycle gets a few more files through before hitting the rate limit again.
Related
- Per-drive sync stays in Aborted after a single 401 on /me/drives, even when subsequent requests succeed #900 (auth error cascading into permanent wedge)
- 3.0 - Server dislikes our behavior, excessive load detected. #734 (server dislikes client behavior / HTTP 420 under load)
- OpenCloud Desktop client freezes #812 (desktop client freezes during large sync — may share root cause)
Activity
agent00bob commentedon Jun 15, 2026
Sanitized log excerpt from the Mac Mini reproducing the download-side failure:
agent00bob commentedon Jun 15, 2026
Sanitized log excerpts from the MBP showing the upload-side failure across 4 consecutive restart cycles:
guruz commentedon Jun 15, 2026
Are the several checks by the same desktop client?
Or is that a global error message that happened because different clients at same time triggered the error?
Which HTTP code? (server side log?)
(You can also get more client side logs if desired with
QT_LOGGING_RULES="qt.network.http2.*=true;qt.network.access.*=true;qt.network.ssl.*=true")agent00bob commentedon Jun 15, 2026
Update: root cause identified and confirmed.
We reproduced and confirmed the root cause with debug logging on both the OpenCloud server and our OIDC provider (Pocket ID v2.8.0, SQLite backend, running on the same Docker host behind Caddy).
Environment: Pocket ID as OIDC provider, single desktop client (MBP, macOS 25.5.0, client 3.0.3.2073), Mac Mini client shut down during upload sync from the MBP.
HTTP status code: The OpenCloud proxy receives 429 Too Many Requests from Pocket ID's userinfo endpoint:
Root cause: OpenCloud's proxy appears to call
/api/oidc/userinfoon every request to validate the access token — no caching(?). During a sync with several hundred files, this produces 30+ userinfo calls per second. Pocket ID's built-in rate limiter triggers, returns 429 for all subsequent requests in that window, and the cascade begins.From the Pocket ID server logs at the moment of failure — all within the same second:
Immediately before the rate limiter fired, SQL query latencies were climbing from sub-millisecond to 5-12ms under the load, but all responses were still 200. The rate limiter, not SQLite contention, terminated the requests.
Fix confirmed: Setting
DISABLE_RATE_LIMITING=trueon Pocket ID resolved the issue and both desktop clients (MBP and Mac Mini) now sync the full space without interruption. In our setup, Pocket ID is an internal service behind Caddy with CrowdSec handling external rate limiting, so the built-in rate limiter was only seeing internal traffic from OpenCloud's proxy.Two issues remain:
OpenCloud proxy — no userinfo caching. The proxy validates the access token by calling the OIDC provider's userinfo endpoint on every request. Since the token doesn't change between refreshes, caching the validation result for the token's lifetime would reduce load on the auth server from 30+/second to effectively zero between refreshes. Any OIDC provider with rate limiting enabled (which is a reasonable default) will eventually reject this volume.
Desktop client —
JobQueue::clear()on transient auth errors. Even with the rate limiter as the trigger, aborting all in-flight uploads and downloads on a 429 is disproportionate. The rate limit is brief and self-resolving — retry with backoff would survive it. Additionally, with the rate limiting in place, Pause Sync / Resume Sync within the app does not restart the sync after an abort; the only recovery is quitting and relaunching the client.I'll leave
DISABLE_RATE_LIMITINGin place for now, but it's not the state I prefer to operate in. Thank you for your quick initial reply to the issue!guruz commentedon Jun 16, 2026
Thank you for the interesting info...
Good that you found a workaround for now.
CC @rhafer
Also @fpusan as I think this is same as in opencloud-eu/opencloud#3225
I agree, but the 429 is sent to the server and not to the client. Something for server team to discuss about... @rhafer etc..
fix(creds): keep the job queue alive across transient token refreshes
test(oauth): regression test for transient token-refresh error handling
fix(creds): keep the job queue alive across transient token refreshes
test(oauth): regression test for transient token-refresh error handling
github-actions commentedon Jul 17, 2026
This issue was marked stale because it has been open for 30 days with no activity. Remove the stale label or comment or this will be closed in 7 days.
fpusan commentedon Jul 17, 2026
Not stale?
TheOneRing commentedon Jul 20, 2026
Fixed in #955