From dd94f17a9c04c8ba193d73f4607f60b4b314ab73 Mon Sep 17 00:00:00 2001 From: forehalo Date: Thu, 9 Nov 2023 18:29:00 +0800 Subject: [PATCH] perf: avoid select all field when list blob keys --- libs/jwst-storage/src/storage/blobs/blob_storage.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/libs/jwst-storage/src/storage/blobs/blob_storage.rs b/libs/jwst-storage/src/storage/blobs/blob_storage.rs index e7b92137..d305e69e 100644 --- a/libs/jwst-storage/src/storage/blobs/blob_storage.rs +++ b/libs/jwst-storage/src/storage/blobs/blob_storage.rs @@ -42,6 +42,7 @@ impl BlobDBStorage { async fn keys(&self, workspace: &str) -> Result, DbErr> { Blobs::find() .filter(BlobColumn::WorkspaceId.eq(workspace)) + .select_only() .column(BlobColumn::Hash) .all(&self.pool) .await