adutra commented on code in PR #15112:
URL: https://github.com/apache/iceberg/pull/15112#discussion_r2720304331
##########
open-api/rest-catalog-open-api.yaml:
##########
@@ -1249,6 +1249,41 @@ paths:
5XX:
$ref: '#/components/responses/ServerErrorResponse'
+ /v1/{prefix}/namespaces/{namespace}/tables/{table}/sign/{provider}:
Review Comment:
It's not that easy.
As an example, a request to sign looks like the one below for S3:
```
PUT /warehouse/db/sales_table/data/date=2024-05/00022-44-55.parquet HTTP/1.1
Host: my-datalake.s3.us-east-1.amazonaws.com
Date: Fri, 24 May 2024 12:45:00 GMT
Content-Length: 134217728
Content-Type: application/octet-stream
```
A similar request to GCP would look like:
```
POST
/upload/storage/v1/b/my-datalake-bucket/o?uploadType=media&name=warehouse/db/sales/data/file.parquet
HTTP/1.1
Host: storage.googleapis.com
Date: Fri, 24 May 2024 12:45:00 GMT
Content-Length: 134217728
Content-Type: application/octet-stream
```
And for Azure:
```
PATCH
/my-container/warehouse/db/sales/data/file.parquet?action=append&position=0
HTTP/1.1
Host: my-datalake.dfs.core.windows.net
x-ms-date: Fri, 24 May 2024 12:45:00 GMT
x-ms-version: 2023-11-03
Content-Length: 134217728
Content-Type: application/octet-stream
```
The question is: how do you know the object storage provider so that the
server can pick the right signing algorithm? The only (heuristic) way is to
inspect the `Host` header, but that's brittle. It's much simpler if the client
tells the server what object storage provider to use.
--
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]