flyrain commented on code in PR #16131:
URL: https://github.com/apache/iceberg/pull/16131#discussion_r3770965106


##########
core/src/main/java/org/apache/iceberg/rest/RESTSessionCatalog.java:
##########
@@ -740,13 +757,17 @@ public Table registerTable(
 
     trackFileIO(ops);
 
-    RESTTable restTable = restTableForScanPlanning(ops, ident, tableClient, 
tableConf);
+    RESTTable restTable =
+        restTableForScanPlanning(ops, ident, tableClient, tableConf, 
ReadRestrictions.empty());

Review Comment:
   [P1] This discards `response.readRestrictions()` and attaches 
`ReadRestrictions.empty()` to the returned table. `Builder.create()` has the 
same pattern. Because both endpoints deserialize `LoadTableResponse`, a server 
can legally include restrictions and these paths will silently return an 
unrestricted table. Please pass the response restrictions through all 
`LoadTableResponse` paths (and cover create/register with end-to-end tests).



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

Reply via email to