FANNG1 commented on code in PR #7444:
URL: https://github.com/apache/gravitino/pull/7444#discussion_r2157886031


##########
iceberg/iceberg-rest-server/src/main/java/org/apache/gravitino/iceberg/service/rest/IcebergConfigOperations.java:
##########
@@ -41,12 +46,30 @@ public class IcebergConfigOperations {
   @Context
   private HttpServletRequest httpRequest;
 
+  private final IcebergCatalogWrapperManager catalogWrapperManager;
+
+  @Inject
+  public IcebergConfigOperations(IcebergCatalogWrapperManager 
catalogWrapperManager) {
+    this.catalogWrapperManager = catalogWrapperManager;
+  }
+
   @GET
   @Produces(MediaType.APPLICATION_JSON)
   @Timed(name = "config." + MetricNames.HTTP_PROCESS_DURATION, absolute = true)
   @ResponseMetered(name = "config", absolute = true)
-  public Response getConfig() {
-    ConfigResponse response = ConfigResponse.builder().build();
+  public Response getConfig(@DefaultValue("") @QueryParam("warehouse") String 
warehouse) {
+    if (warehouse == null || warehouse.isEmpty()) {

Review Comment:
   As an improvement if the warehouse is empty, we could use 
`IcebergConstants.ICEBERG_REST_DEFAULT_CATALOG` as the default catalog to 
retrieve catalog config, but we could do the  improvement in another PR.



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

Reply via email to