From 7611f05f371c8ef9b88aa64068996551791908ad Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Tue, 25 Nov 2025 20:15:35 -0800 Subject: [PATCH] Document credential store HA limitation with TODO Addresses review comment on auth_credentials.go:149 Changes: - Add TODO comment documenting that SetFilerClient interface needs update for multi-filer support - Add informative log message indicating HA limitation - Document that this is a known limitation for filer-backed credential stores The SetFilerClient interface currently only accepts a single filer address. To properly support HA, the credential store interfaces need to be updated to handle multiple filer addresses. --- weed/s3api/auth_credentials.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/weed/s3api/auth_credentials.go b/weed/s3api/auth_credentials.go index e9c6bbedc..795ef6d86 100644 --- a/weed/s3api/auth_credentials.go +++ b/weed/s3api/auth_credentials.go @@ -137,14 +137,17 @@ func NewIdentityAccessManagementWithStore(option *S3ApiServerOption, explicitSto } // For stores that need filer client details, set them + // Note: SetFilerClient interface currently accepts only a single filer address + // TODO: Update credential store interfaces to support multiple filers for HA + // For now, using first filer - this is a known limitation for filer-backed stores if store := credentialManager.GetStore(); store != nil { if filerClientSetter, ok := store.(interface { SetFilerClient(string, grpc.DialOption) }); ok { - // Use the first filer address for credential store if len(option.Filers) > 0 { filerAddr := option.Filers[0].ToGrpcAddress() filerClientSetter.SetFilerClient(filerAddr, option.GrpcDialOption) + glog.V(1).Infof("Credential store configured with first filer: %s (HA limitation)", filerAddr) } else { glog.Warningf("No filer addresses configured for credential store") }