huaxingao commented on code in PR #4659:
URL: https://github.com/apache/polaris/pull/4659#discussion_r3430170061


##########
CHANGELOG.md:
##########
@@ -52,6 +53,7 @@ request adding CHANGELOG notes for breaking (!) changes and 
possibly other secti
 - Added support for `register table` overwrite semantics in the Iceberg REST 
catalog flow (`overwrite=true`) for internal Polaris catalogs. With overwrite 
enabled, existing table pointers can be updated to a new metadata location 
while preserving default behavior for `overwrite=false`.
 - Added `REGISTER_TABLE_OVERWRITE` authorization operation mapped to 
`TABLE_FULL_METADATA` for deterministic overwrite authorization.
 - Added Polaris Spark 4.0 client.
+- Added handler-level support for the Iceberg REST `Idempotency-Key` header on 
`createTable`, using an optimistic-commit model: the terminal outcome is 
recorded only after a successful (2xx) response and retries replay an 
equivalent response rebuilt from current catalog state (no response body is 
stored). The key is bound to the request-derived resource (operation, 
namespace, name and access-delegation modes) and the caller principal, so 
reusing a key for a different resource or by a different caller is rejected 
with HTTP 422. A retry that loses a concurrent create race replays the winning 
request instead of returning 409, and a replay returns 422 if the table has 
advanced beyond the originally-created state. Only successful outcomes are 
recorded — a retry after a failure simply re-runs the operation. Idempotency is 
disabled by default and configured under `polaris.idempotency`; records are 
kept in a standalone idempotency store decoupled from the metastore persistence.

Review Comment:
   Thanks @snazy ! Applied your changelog suggestion. And good point on the 
schema: agreed it's better to land relational schema together with the code 
that uses it (or mark it provisional). I'll keep that in mind for the follow-up 
operations.



-- 
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]

Reply via email to