flyrain commented on code in PR #15180:
URL: https://github.com/apache/iceberg/pull/15180#discussion_r2867114745


##########
open-api/rest-catalog-open-api.yaml:
##########
@@ -4181,6 +4259,38 @@ components:
           items:
             $ref: '#/components/schemas/Namespace'
 
+    LoadFunctionResult:
+      description: |
+        Result returned when a function is loaded from the catalog.
+
+
+        The function metadata JSON is returned in the `metadata` field. The 
location of the metadata
+        file is returned in the `metadata-location` field.
+
+
+        The `config` map returns function-specific configuration for accessing 
the function's resources,
+        including any required credentials or client configuration overrides.
+      type: object
+      required:
+        - metadata-location
+        - metadata
+      properties:
+        metadata-location:
+          type: string
+        metadata:
+          type: object
+          description: >
+            The function's full spec/metadata document, returned inline as 
JSON.
+
+
+            The structure of this JSON document is defined by the Iceberg UDF 
spec.
+            The spec format version is identified by the `format-version` 
field in the returned metadata.
+          additionalProperties: true
+        config:
+          type: object
+          additionalProperties:
+            type: string

Review Comment:
   I took a closer look at the `config` field. From what I understand, it is 
primarily used for FileIO configuration in `LoadTableResult`. For UDFs, I am 
not sure this is strictly necessary, since the UDF metadata itself should 
already contain everything an engine needs. In principle, engines should not 
need to rely on FileIO to load additional resources.
   
   That said, I noticed that `LoadViewResult` also includes a `config` map, 
even though it may not always require FileIO either. I am a bit unclear on the 
original intent behind including `config` there.
   
   Hi @nastra, would you mind sharing more context on the purpose of the 
`config` map in `LoadViewResult`?
   ```
   The `config` map returns view specific configuration for the view's 
resources.
   ```



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

Reply via email to