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
listObjects should return NoSuchBucket when the bucket doesn't exist and prefix is passed #32
Thanks for the PR. I looked into the history behind this behavior.
The relevant upstream change is 80ca12008 / minio#18917, which removed the unconditional checkBucketExist call from several object API argument checks. The motivation was performance: GetBucketInfo() can fan out across peers and becomes costly on large distributed deployments, especially with 100+ nodes.
Because of that, I am concerned about reintroducing bucket existence checks too broadly. Moving the check back into the generic ListObjects argument path would effectively undo the upstream optimization and could bring back the same scalability issue.
This PR is much narrower than a full revert, but it is still a user-visible behavior change: some ListObjects calls against a non-existent bucket would change from an empty result to NoSuchBucket. Given that this fork is intended to stay close to upstream and is mainly maintained for binary supply-chain/security purposes, my current preference is to keep this behavior aligned with upstream for non-security fixes.
the change from 80ca12008 was already a user-visible change. We would just re-establish it to the behavior it used to have. In my case I want to upgrade from a version prior to the 80ca12008 and I can't do it precisely because of that behavior change.
The definition of silo/minio is MinIO is a Kubernetes-native S3-compatible object storage solution and S3 returns NoSuchBucket. A lot of (most?) people use Minio as a S3 simulation during unit/integration tests so having the same behavior as S3 is very important.
The accepted fix checks bucket existence only on the three listPath shortcuts that otherwise return EOF before consulting storage: slash-prefixed prefixes, zero limits, and markers outside the prefix. Normal listing remains on the upstream optimized path without a generic GetBucketInfo pre-check.
Repository integration is complete. A future tagged release, package, container image, deployment, and production verification remain separate delivery gates.
Activity
ycjlin commentedon Jun 28, 2026
@cbornet Pls help review my PR. Thanks.
Vonng commentedon Jun 30, 2026
Thanks for the PR. I looked into the history behind this behavior.
The relevant upstream change is
80ca12008/ minio#18917, which removed the unconditionalcheckBucketExistcall from several object API argument checks. The motivation was performance:GetBucketInfo()can fan out across peers and becomes costly on large distributed deployments, especially with 100+ nodes.Because of that, I am concerned about reintroducing bucket existence checks too broadly. Moving the check back into the generic ListObjects argument path would effectively undo the upstream optimization and could bring back the same scalability issue.
This PR is much narrower than a full revert, but it is still a user-visible behavior change: some ListObjects calls against a non-existent bucket would change from an empty result to
NoSuchBucket. Given that this fork is intended to stay close to upstream and is mainly maintained for binary supply-chain/security purposes, my current preference is to keep this behavior aligned with upstream for non-security fixes.cbornet commentedon Aug 20, 2026
I understand your concern but:
NoSuchBucketis more correct.80ca12008was already a user-visible change. We would just re-establish it to the behavior it used to have. In my case I want to upgrade from a version prior to the80ca12008and I can't do it precisely because of that behavior change.MinIO is a Kubernetes-native S3-compatible object storage solutionand S3 returnsNoSuchBucket. A lot of (most?) people use Minio as a S3 simulation during unit/integration tests so having the same behavior as S3 is very important.fix: return NoSuchBucket from listing shortcuts
Vonng commentedon Aug 26, 2026
Resolved and merged via #37.
Final integration record:
e9c5340be49c8aeac4main: VulnCheck and all six Go CI jobs passedThe accepted fix checks bucket existence only on the three
listPathshortcuts that otherwise return EOF before consulting storage: slash-prefixed prefixes, zero limits, and markers outside the prefix. Normal listing remains on the upstream optimized path without a genericGetBucketInfopre-check.Repository integration is complete. A future tagged release, package, container image, deployment, and production verification remain separate delivery gates.