apache / apache/gravitino

[Improvement] Implement remote signing endpoint for Iceberg REST server

Open
#10,682 0 comments 0 reactions 0 assignees View on GitHub
improvement
Dominant language
Java
Stars
3.2k
Forks
935
Avg merge
1d 15h
Merged PRs (30d)
315

Description

### What would you like to be improved?

The Gravitino Iceberg REST server only supports `vended-credentials` for the `X-Iceberg-Access-Delegation` header. Requesting `remote-signing` throws `UnsupportedOperationException` ([IcebergTableOperations.java#L680-L682](https://github.com/apache/gravitino/blob/main/iceberg/iceberg-rest-server/src/main/java/org/apache/gravitino/iceberg/service/rest/IcebergTableOperations.java#L680-L682)), and the `POST /v1/{prefix}/namespaces/{namespace}/tables/{table}/sign` endpoint does not exist. This is a gap against the Iceberg REST spec and blocks clients (e.g., PyIceberg) that prefer remote signing over receiving cloud credentials directly.

### How should we improve?

- Add `POST .../tables/{table}/sign` endpoint in `IcebergTableOperations` accepting `RemoteSignRequest` and returning `RemoteSignResult`
- Update `isCredentialVending()` to support `remote-signing` as a valid delegation mode
- Advertise the `/sign` endpoint in the config response endpoints list
- Add unit and integration tests

Contributor guide

Open the contributing guide

Research direction

Start in iceberg/iceberg-rest-server/src/main/java/org/apache/gravitino/iceberg/service/rest/IcebergTableOperations.java, especially the delegation-mode check and the REST operations around the table endpoints. Compare the Iceberg REST specification for remote signing, then add coverage for the sign request/result, delegation mode, and advertised endpoint. Done means remote-signing requests no longer throw UnsupportedOperationException and unit and integration tests pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api, backend-api-design
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.