S3 ListObjectsV2 fix pagination under bucket root

fix https://github.com/chrislusf/seaweedfs/issues/3166
This commit is contained in:
chrislu 2022-07-06 02:28:34 -07:00
parent bfea7008f3
commit 69ef6459c3

View file

@ -281,7 +281,7 @@ func (s3a *S3ApiServer) doListFilerEntries(client filer_pb.SeaweedFilerClient, d
request := &filer_pb.ListEntriesRequest{ request := &filer_pb.ListEntriesRequest{
Directory: dir, Directory: dir,
Prefix: prefix, Prefix: prefix,
Limit: uint32(maxKeys + 1), Limit: uint32(maxKeys + 2), // bucket root directory needs to skip additional s3_constants.MultipartUploadsFolder folder
StartFromFileName: marker, StartFromFileName: marker,
InclusiveStartFrom: inclusiveStartFrom, InclusiveStartFrom: inclusiveStartFrom,
} }