kbendick commented on code in PR #4448:
URL: https://github.com/apache/iceberg/pull/4448#discussion_r865421427
##########
core/src/main/java/org/apache/iceberg/rest/RESTCatalog.java:
##########
@@ -113,7 +114,14 @@ public boolean dropTable(TableIdentifier identifier,
boolean purge) {
@Override
public void renameTable(TableIdentifier from, TableIdentifier to) {
+ RenameTableRequest request = RenameTableRequest.builder()
+ .withSource(from)
+ .withDestination(to)
+ .build();
+ // for now, ignore the response because there is no way to return it.
+ // also, the spec does not define a response beyond simply `ok`.
+ client.post("v1/tables/rename", request, null,
ErrorHandlers.tableErrorHandler());
Review Comment:
The 200 content does say the POST body should have the updated information
in it though, so I'm ok either way:
https://www.rfc-editor.org/rfc/rfc2616#section-10.2.1
```
[10.2.1](https://www.rfc-editor.org/rfc/rfc2616#section-10.2.1) 200 OK
The request has succeeded. The information returned with the response
is dependent on the method used in the request, for example:
GET ....
POST an entity describing or containing the result of the action;
```
--
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]