SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
fix: handle 'default' collection filter in cluster volumes page
chrisluc56a0a0ebdff
diff --git a/weed/admin/dash/ec_shard_management.go b/weed/admin/dash/ec_shard_management.goindex 82aa4074d8..330d89fd58 100644--- a/weed/admin/dash/ec_shard_management.go+++ b/weed/admin/dash/ec_shard_management.go@@ -16,8 +16,8 @@ import (// matchesCollection checks if a volume/EC volume collection matches the filter collection.// Handles the special case where empty collection ("") represents the "default" collection.func matchesCollection(volumeCollection, filterCollection string) bool {- // Both empty means default collection matches default filter- if volumeCollection == "" && filterCollection == "" {+ // Handle special case where "default" filter matches empty collection+ if filterCollection == "default" && volumeCollection == "" {return true}// Direct string match for named collectionsdiff --git a/weed/admin/handlers/cluster_handlers.go b/weed/admin/handlers/cluster_handlers.goindex 1a58e919dc..9034ed6881 100644--- a/weed/admin/handlers/cluster_handlers.go+++ b/weed/admin/handlers/cluster_handlers.go@@ -170,12 +170,6 @@ func (h *ClusterHandlers) ShowCollectionDetails(c *gin.Context) {return}- // Map "default" collection to empty string for backend filtering- actualCollectionName := collectionName- if collectionName == "default" {- actualCollectionName = ""- }-// Parse query parameterspage, _ := strconv.Atoi(c.DefaultQuery("page", "1"))pageSize, _ := strconv.Atoi(c.DefaultQuery("page_size", "25"))@@ -183,7 +177,7 @@ func (h *ClusterHandlers) ShowCollectionDetails(c *gin.Context) {sortOrder := c.DefaultQuery("sort_order", "asc")// Get collection details data (volumes and EC volumes)- collectionDetailsData, err := h.adminServer.GetCollectionDetails(actualCollectionName, page, pageSize, sortBy, sortOrder)+ collectionDetailsData, err := h.adminServer.GetCollectionDetails(collectionName, page, pageSize, sortBy, sortOrder)if err != nil {c.JSON(http.StatusInternalServerError, gin.H{"error": "Failed to get collection details: " + err.Error()})return