You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "plusplusjiajia (via GitHub)" <gi...@apache.org> on 2026/08/14 05:55:38 UTC

[PR] feat(rest): wrap catalog responses in HttpResponse [iceberg-rust]

plusplusjiajia opened a new pull request, #2996:
URL: https://github.com/apache/iceberg-rust/pull/2996

   ## Which issue does this PR close?
   
     Closes [#2993](https://github.com/apache/iceberg-rust/issues/2993).
   
   ## What changes are included in this PR?
   
       [#2838](https://github.com/apache/iceberg-rust/pull/2838) added `HttpRequest` so the catalog layer works with `http` types instead of `reqwest`. Responses were still unwrapped. This adds the counterpart.
   
     - New `response.rs` (mirroring `request.rs`) with `HttpResponse { status, headers, body }`. `query_catalog` and `post_form` return it, so `reqwest::Response` no longer appears outside `HttpClient` — `catalog.rs` doesn't even import it any more.
     - `deserialize_catalog_response` and `deserialize_unexpected_catalog_error` are no longer `async`: the body is already read.
     - `post_form` returns `HttpResponse` instead of `(StatusCode, Vec<u8>)`. Breaking, but that method landed in #2838 and hasn't been released.


-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(rest): wrap catalog responses in HttpResponse [iceberg-rust]

Posted by "plusplusjiajia (via GitHub)" <gi...@apache.org>.
plusplusjiajia commented on code in PR #2996:
URL: https://github.com/apache/iceberg-rust/pull/2996#discussion_r3809515427


##########
crates/catalog/rest/src/client.rs:
##########
@@ -182,13 +178,13 @@ impl HttpClient {
 
     // Queries the Iceberg REST catalog after authentication with the given `Request` and
     // returns a `Response`.
-    pub(crate) async fn query_catalog(&self, mut request: HttpRequest) -> Result<Response> {
+    pub(crate) async fn query_catalog(&self, mut request: HttpRequest) -> Result<HttpResponse> {

Review Comment:
   @anoopj @CTTY  Good catch — fixed.



-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(rest): wrap catalog responses in HttpResponse [iceberg-rust]

Posted by "CTTY (via GitHub)" <gi...@apache.org>.
CTTY merged PR #2996:
URL: https://github.com/apache/iceberg-rust/pull/2996


-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(rest): wrap catalog responses in HttpResponse [iceberg-rust]

Posted by "anoopj (via GitHub)" <gi...@apache.org>.
anoopj commented on code in PR #2996:
URL: https://github.com/apache/iceberg-rust/pull/2996#discussion_r3786039643


##########
crates/catalog/rest/src/client.rs:
##########
@@ -182,13 +178,13 @@ impl HttpClient {
 
     // Queries the Iceberg REST catalog after authentication with the given `Request` and
     // returns a `Response`.
-    pub(crate) async fn query_catalog(&self, mut request: HttpRequest) -> Result<Response> {
+    pub(crate) async fn query_catalog(&self, mut request: HttpRequest) -> Result<HttpResponse> {

Review Comment:
   Is `Request` and `Response` in the method doc stale? (need to be updated to the new classes)



-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] feat(rest): wrap catalog responses in HttpResponse [iceberg-rust]

Posted by "CTTY (via GitHub)" <gi...@apache.org>.
CTTY commented on code in PR #2996:
URL: https://github.com/apache/iceberg-rust/pull/2996#discussion_r3808926862


##########
crates/catalog/rest/src/client.rs:
##########
@@ -182,13 +178,13 @@ impl HttpClient {
 
     // Queries the Iceberg REST catalog after authentication with the given `Request` and
     // returns a `Response`.
-    pub(crate) async fn query_catalog(&self, mut request: HttpRequest) -> Result<Response> {
+    pub(crate) async fn query_catalog(&self, mut request: HttpRequest) -> Result<HttpResponse> {

Review Comment:
   +1, we should fix the doc reference



-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org