YuangGao opened a new pull request, #4310: URL: https://github.com/apache/iceberg-python/pull/4310
Closes #4290 # Rationale for this change - A REST server can advertise `idempotency-key-lifetime`, after which clients send an `Idempotency-Key` (UUIDv7) on mutations and reuse it on retry, so a retried commit can't apply twice. PyIceberg sent no key and never retried `POST`. - With the lifetime advertised, each mutation now carries a fresh key, and the `rest.client.*` retry policy also covers `POST`, reusing the key across retries, as Java's `RESTSessionCatalog` does. - The lifetime itself isn't enforced: urllib3 retries are bounded and finish well within typical lifetimes. ## Are these changes tested? - `test_rest.py` — mutations carry a UUIDv7 key only when advertised, a different one per operation, and reads carry none; a `POST` retried after a 503 reuses its key. ## Are there any user-facing changes? - Against servers that advertise `idempotency-key-lifetime`, mutations send `Idempotency-Key` and `POST` is retried under `rest.client.*`. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
