mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-12-04 18:17:16 +01:00
* kms: read filer.toml and the identities file with one parser The KMS settings from filer.toml and from the identities file went through two paths: the JSON one was wrapped in an adapter so it could be read like viper. Both are now parsed into the same settings and loaded by the same code. Viper lowercases the provider tables in filer.toml but not the values that name a provider, so a mixed-case default_provider or bucket provider never matched and failed the load. Those values are now lowercased for filer.toml. Providers load in name order, a providers or buckets section that isn't a table fails the load instead of being ignored, and so does a default_provider that isn't a string. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * kms: test the parser's section types and JSON provider names A providers or buckets section that isn't a table and a default_provider that isn't a string fail the parse, and a JSON config keeps the case of the provider names it uses. The check-once test now loads through the whole loader, which sets the global provider, so it clears it after. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * kms: pick the first provider by name when no default is set ListKMSProviders iterated the provider map, so with several providers and no default_provider the global SSE-KMS provider changed between loads, and objects written under one could not be read after a restart. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * s3api: report KMS load errors from the identities file Any failure loading the identities file's kms block was logged at V(2) as no KMS configuration, which hid the parser's errors and a default_provider that does not exist. Only a missing block is quiet now. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Chris Lu <chrislusf@users.noreply.github.com>