jerqi commented on code in PR #4055:
URL: https://github.com/apache/gravitino/pull/4055#discussion_r1771016853


##########
core/src/main/java/org/apache/gravitino/EntityStore.java:
##########
@@ -55,15 +56,40 @@ public interface EntityStore extends Closeable {
    * <p>Note. Depends on the isolation levels provided by the underlying 
storage, the returned list
    * may not be consistent.
    *
-   * @param namespace the namespace of the entities
    * @param <E> class of the entity
+   * @param namespace the namespace of the entities
    * @param type the detailed type of the entity
    * @param entityType the general type of the entity
+   * @return the list of entities
    * @throws IOException if the list operation fails
+   */
+  default <E extends Entity & HasIdentifier> List<E> list(
+      Namespace namespace, Class<E> type, EntityType entityType) throws 
IOException {
+    return list(namespace, type, entityType, Collections.emptyList());
+  }
+
+  /**
+   * List all the entities with the specified {@link 
org.apache.gravitino.Namespace}, and
+   * deserialize them into the specified {@link Entity} object.
+   *
+   * <p>Note. Depends on the isolation levels provided by the underlying 
storage, the returned list
+   * may not be consistent.
+   *
+   * @param <E> class of the entity
+   * @param namespace the namespace of the entities
+   * @param type the detailed type of the entity
+   * @param entityType the general type of the entity
+   * @param skippingFields Some fields may have a relatively high acquisition 
cost, EntityStore
+   *     provide an optional setting to avoid fetching these high-cost fields 
to improve the
+   *     performance.
    * @return the list of entities
+   * @throws IOException if the list operation fails
    */
-  <E extends Entity & HasIdentifier> List<E> list(
-      Namespace namespace, Class<E> type, EntityType entityType) throws 
IOException;
+  default <E extends Entity & HasIdentifier> List<E> list(
+      Namespace namespace, Class<E> type, EntityType entityType, List<Field> 
skippingFields)

Review Comment:
   OK.



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