bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_master #582
No reviewers
Labels
No labels
P0
P1
P2
P3
good first issue
Infrastructure
blocked
bug
config
discussion
documentation
duplicate
enhancement
go
help wanted
internal
invalid
kludge
observability
perfomance
question
refactoring
wontfix
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: TrueCloudLab/frostfs-s3-gw#582
Loading…
Reference in a new issue
No description provided.
Delete branch "r.loginov/frostfs-s3-gw:fix/return_another_error_in_case_name_conflict"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
close #583
78d9a3d235
toe6f1e38b04
e6f1e38b04
tof7092d2532
WIP: fix/return_another_error_in_case_name_conflict_and_list_buckets_vhsto bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masterf7092d2532
toef1dfe247f
Please, fix typo in commit
Return BucketAlradyExist when global domain taken
@ -145,3 +147,3 @@
}
if len(filter.allowedQueries) > 0 {
queries := r.URL.Query()
if len(queries) == 0 {
Is it possible to add some tests? Perfectly with checking listing routing (or at least some unit test).
By the way let's move this check into previous
if
Otherwise, as I understand we get some incorrect behavior for regular listing-v1 (because we don't mark it as
NoQuery
, add someAllowedQueries
and want to match iflen(queries)==0
) but now it won't matchYou are right, however, it turned out that my solution does not cover cases. The problem is that list-buckets can also have query parameters according to the specification, and more importantly, list-objects-v1 and list-buckets have one common query parameter, which can be both there and there. Therefore, if there is only this query parameter when requesting list-buckets, we will also fail in list-objects-v1. Ultimately, if we are talking about VHS, then we can distinguish list-buckets from list-objects-v1 only by the presence of a bucket in the URL. Now I will post a new version of the fixes that takes this into account and also takes into account your scenario (listing-v1 query with
len(queries)==0
) and as a result, an additionalif
is not needed.Created #585 to support query parameters in
ListBuckets
bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masterto WIP: bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masteref1dfe247f
to9a8407e8cf
New commits pushed, approval review dismissed automatically according to repository settings
9a8407e8cf
tofe696ebade
WIP: bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masterto bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masterbugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masterto WIP: bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_master@ -341,2 +339,2 @@
Add(NewFilter().
NoQueries().
s3middleware.QueryMarker, s3middleware.QueryEncodingType, s3middleware.QueryBucketRegion,
s3middleware.QueryContinuationToken, s3middleware.QueryMaxBuckets).
Can we consider something like this? I think we should keep "bucket" router only bucket related operations.
ListBuckets
doesn't belong to itfe696ebade
to4ef22aa46d
WIP: bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_masterto bugfix/return_another_error_in_case_name_conflict_and_list_buckets_vhs_master