You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Pooled S3 clients ignored the configured endpoint, so ObjectFS could not address any S3-compatible storage #173
Found while wiring the substrate-backed test harness; not on the v0.10.0 audit list.
What was wrong
NewClientManager built four S3 clients. Three applied cfg.Endpoint and cfg.ForcePathStyle; the connection pool's factory called s3.NewFromConfig(awsCfg) with no options at all.
Proven by execution against a configured endpoint of http://localhost:14566:
DIRECT BaseEndpoint=http://localhost:14566 UsePathStyle=true
POOLED BaseEndpoint=<nil> UsePathStyle=false
Consequence
These operations draw from the pool, so all of them addressed real AWS S3 regardless of configuration:
HeadObject — every stat, every Lookup
DeleteObject
ListObjects — every readdir
ClientManager.HealthCheck — which runs during NewBackend, so the mount failed at startup
the non-accelerated path of executeWithAccelerationFallback
PutObject and GetObject meanwhile addressed the configured endpoint. ObjectFS therefore could not work against MinIO, Ceph, Wasabi, an emulator, or any other S3-compatible endpoint — and the failure surfaced as a 403/404 from AWS, which reads as a credentials or bucket-name problem rather than a configuration bug.
use_dual_stack was likewise defined in config and applied by nothing.
Fix
One shared clientOptions(cfg) func(*s3.Options) mutator, used by all four construction sites including the pool factory. client_endpoint_test.go asserts the property rather than the mechanism: it enumerates the manager's client accessors, so a client added later without the options fails there rather than in production.
Activity