{"action":"created","comment":{"url":"https://api.github.com/repos/minio/minio/pulls/comments/184766027","pull_request_review_id":116033077,"id":184766027,"diff_hunk":"@@ -505,11 +512,116 @@ func (a *azureObjects) DeleteBucket(ctx context.Context, bucket string) error {\n \treturn azureToObjectError(err, bucket)\n }\n \n+// Filter out the entries which are lexicographically <= marker and return the rest of the listing.\n+func (a *azureObjects) filterListObjects(ctx context.Context, bucket, prefix, marker, delimiter string, maxKeys int) (result minio.ListObjectsInfo, err error) {\n+\tvar objects []minio.ObjectInfo\n+\tvar prefixes []string\n+\tcontainer := a.client.GetContainerReference(bucket)\n+\tazureListMarker := \"\"\n+\tfor {\n+\t\tresp, err := container.ListBlobs(storage.ListBlobsParameters{\n+\t\t\tPrefix:     prefix,\n+\t\t\tMarker:     azureListMarker,\n+\t\t\tDelimiter:  delimiter,\n+\t\t\tMaxResults: uint(maxKeys),\n+\t\t})\n+\t\tif err != nil {\n+\t\t\tlogger.LogIf(ctx, err)\n+\t\t\treturn result, azureToObjectError(err, bucket, prefix)\n+\t\t}\n+\t\tazureListMarker = resp.NextMarker\n+\t\ti := 0\n+\t\t// Skip entries <= marker\n+\t\tfor ; i < len(resp.Blobs); i++ {\n+\t\t\tobject := resp.Blobs[i]\n+\t\t\tif strings.HasPrefix(object.Name, minio.GatewayMinioSysTmp) {","path":"cmd/gateway/azure/gateway-azure.go","position":47,"original_position":47,"commit_id":"71406aabf31127b09b16ddf00c7c2b05d6767d9a","original_commit_id":"71406aabf31127b09b16ddf00c7c2b05d6767d9a","user":{"login":"harshavardhana","id":622699,"avatar_url":"https://avatars0.githubusercontent.com/u/622699?v=4","gravatar_id":"","url":"https://api.github.com/users/harshavardhana","html_url":"https://github.com/harshavardhana","followers_url":"https://api.github.com/users/harshavardhana/followers","following_url":"https://api.github.com/users/harshavardhana/following{/other_user}","gists_url":"https://api.github.com/users/harshavardhana/gists{/gist_id}","starred_url":"https://api.github.com/users/harshavardhana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harshavardhana/subscriptions","organizations_url":"https://api.github.com/users/harshavardhana/orgs","repos_url":"https://api.github.com/users/harshavardhana/repos","events_url":"https://api.github.com/users/harshavardhana/events{/privacy}","received_events_url":"https://api.github.com/users/harshavardhana/received_events","type":"User","site_admin":false},"body":":+1: ","created_at":"2018-04-27T18:10:24Z","updated_at":"2018-04-27T18:10:24Z","html_url":"https://github.com/minio/minio/pull/5856#discussion_r184766027","pull_request_url":"https://api.github.com/repos/minio/minio/pulls/5856","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/minio/minio/pulls/comments/184766027"},"html":{"href":"https://github.com/minio/minio/pull/5856#discussion_r184766027"},"pull_request":{"href":"https://api.github.com/repos/minio/minio/pulls/5856"}},"in_reply_to_id":184576770},"pull_request":{"url":"https://api.github.com/repos/minio/minio/pulls/5856","id":184181881,"html_url":"https://github.com/minio/minio/pull/5856","diff_url":"https://github.com/minio/minio/pull/5856.diff","patch_url":"https://github.com/minio/minio/pull/5856.patch","issue_url":"https://api.github.com/repos/minio/minio/issues/5856","number":5856,"state":"open","locked":false,"title":"Support for ListObjectsV1 style marker for Azure gateway","user":{"login":"krishnasrinivas","id":634494,"avatar_url":"https://avatars0.githubusercontent.com/u/634494?v=4","gravatar_id":"","url":"https://api.github.com/users/krishnasrinivas","html_url":"https://github.com/krishnasrinivas","followers_url":"https://api.github.com/users/krishnasrinivas/followers","following_url":"https://api.github.com/users/krishnasrinivas/following{/other_user}","gists_url":"https://api.github.com/users/krishnasrinivas/gists{/gist_id}","starred_url":"https://api.github.com/users/krishnasrinivas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krishnasrinivas/subscriptions","organizations_url":"https://api.github.com/users/krishnasrinivas/orgs","repos_url":"https://api.github.com/users/krishnasrinivas/repos","events_url":"https://api.github.com/users/krishnasrinivas/events{/privacy}","received_events_url":"https://api.github.com/users/krishnasrinivas/received_events","type":"User","site_admin":false},"body":"fixes #4948\r\n\r\n<!--- Provide a general summary of your changes in the Title above -->\r\n\r\n## Description\r\n<!--- Describe your changes in detail -->\r\nAzure expects marker (https://docs.microsoft.com/en-us/rest/api/storageservices/List-Blobs?redirectedfrom=MSDN) in the ListBlobs request to be the nextmarker field of the previous ListBlobs result.\r\n\r\nThe marker is an opaque value.\r\n\r\nArq 5, does not use Azure's ListBlobs result for the marker and uses the object name directly (which is allowed in the S3 protocol)\r\n\r\nTo support such a List request:\r\n```\r\n        // To accommodate S3-compatible applications using\r\n        // ListObjectsV1 to use object keys as markers to control the\r\n        // listing of objects, we use the following encoding scheme to\r\n        // distinguish between Azure continuation tokens and application\r\n        // supplied markers.\r\n        //\r\n        // - NextMarker in ListObjectsV1 response is constructed by\r\n        //   prefixing \"{minio}\" to the Azure continuation token,\r\n        //   e.g, \"{minio}CgRvYmoz\"\r\n        //\r\n        // - Application supplied markers are used as-is to list\r\n        //   object keys that appear after it in the lexicographical order.\r\n```\r\n\r\n## How Has This Been Tested?\r\n<!--- Please describe in detail how you tested your changes. -->\r\n<!--- Include details of your testing environment, and the tests you ran to -->\r\n<!--- see how your change affects other areas of the code, etc. -->\r\nmanual\r\n\r\n## Types of changes\r\n<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->\r\n- [x] Bug fix (non-breaking change which fixes an issue)\r\n- [ ] New feature (non-breaking change which adds functionality)\r\n- [ ] Breaking change (fix or feature that would cause existing functionality to change)\r\n\r\n## Checklist:\r\n<!--- Go over all the following points, and put an `x` in all the boxes that apply. -->\r\n<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->\r\n- [ ] My code follows the code style of this project.\r\n- [ ] My change requires a change to the documentation.\r\n- [ ] I have updated the documentation accordingly.\r\n- [ ] I have added unit tests to cover my changes.\r\n- [ ] I have added/updated functional tests in [mint](https://github.com/minio/mint). (If yes, add `mint` PR # here: )\r\n- [ ] All new and existing tests passed.","created_at":"2018-04-25T22:35:03Z","updated_at":"2018-04-27T18:10:24Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1ebd3d2c6734d0b74a53bfe54abd6574870bd919","assignee":null,"assignees":[],"requested_reviewers":[{"login":"donatello","id":200059,"avatar_url":"https://avatars0.githubusercontent.com/u/200059?v=4","gravatar_id":"","url":"https://api.github.com/users/donatello","html_url":"https://github.com/donatello","followers_url":"https://api.github.com/users/donatello/followers","following_url":"https://api.github.com/users/donatello/following{/other_user}","gists_url":"https://api.github.com/users/donatello/gists{/gist_id}","starred_url":"https://api.github.com/users/donatello/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/donatello/subscriptions","organizations_url":"https://api.github.com/users/donatello/orgs","repos_url":"https://api.github.com/users/donatello/repos","events_url":"https://api.github.com/users/donatello/events{/privacy}","received_events_url":"https://api.github.com/users/donatello/received_events","type":"User","site_admin":false},{"login":"krisis","id":522593,"avatar_url":"https://avatars3.githubusercontent.com/u/522593?v=4","gravatar_id":"","url":"https://api.github.com/users/krisis","html_url":"https://github.com/krisis","followers_url":"https://api.github.com/users/krisis/followers","following_url":"https://api.github.com/users/krisis/following{/other_user}","gists_url":"https://api.github.com/users/krisis/gists{/gist_id}","starred_url":"https://api.github.com/users/krisis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krisis/subscriptions","organizations_url":"https://api.github.com/users/krisis/orgs","repos_url":"https://api.github.com/users/krisis/repos","events_url":"https://api.github.com/users/krisis/events{/privacy}","received_events_url":"https://api.github.com/users/krisis/received_events","type":"User","site_admin":false},{"login":"harshavardhana","id":622699,"avatar_url":"https://avatars0.githubusercontent.com/u/622699?v=4","gravatar_id":"","url":"https://api.github.com/users/harshavardhana","html_url":"https://github.com/harshavardhana","followers_url":"https://api.github.com/users/harshavardhana/followers","following_url":"https://api.github.com/users/harshavardhana/following{/other_user}","gists_url":"https://api.github.com/users/harshavardhana/gists{/gist_id}","starred_url":"https://api.github.com/users/harshavardhana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harshavardhana/subscriptions","organizations_url":"https://api.github.com/users/harshavardhana/orgs","repos_url":"https://api.github.com/users/harshavardhana/repos","events_url":"https://api.github.com/users/harshavardhana/events{/privacy}","received_events_url":"https://api.github.com/users/harshavardhana/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":574010436,"url":"https://api.github.com/repos/minio/minio/labels/priority:%20high","name":"priority: high","color":"FF530D","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/minio/minio/pulls/5856/commits","review_comments_url":"https://api.github.com/repos/minio/minio/pulls/5856/comments","review_comment_url":"https://api.github.com/repos/minio/minio/pulls/comments{/number}","comments_url":"https://api.github.com/repos/minio/minio/issues/5856/comments","statuses_url":"https://api.github.com/repos/minio/minio/statuses/71406aabf31127b09b16ddf00c7c2b05d6767d9a","head":{"label":"krishnasrinivas:azure-list-marker-fix","ref":"azure-list-marker-fix","sha":"71406aabf31127b09b16ddf00c7c2b05d6767d9a","user":{"login":"krishnasrinivas","id":634494,"avatar_url":"https://avatars0.githubusercontent.com/u/634494?v=4","gravatar_id":"","url":"https://api.github.com/users/krishnasrinivas","html_url":"https://github.com/krishnasrinivas","followers_url":"https://api.github.com/users/krishnasrinivas/followers","following_url":"https://api.github.com/users/krishnasrinivas/following{/other_user}","gists_url":"https://api.github.com/users/krishnasrinivas/gists{/gist_id}","starred_url":"https://api.github.com/users/krishnasrinivas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krishnasrinivas/subscriptions","organizations_url":"https://api.github.com/users/krishnasrinivas/orgs","repos_url":"https://api.github.com/users/krishnasrinivas/repos","events_url":"https://api.github.com/users/krishnasrinivas/events{/privacy}","received_events_url":"https://api.github.com/users/krishnasrinivas/received_events","type":"User","site_admin":false},"repo":{"id":39705039,"name":"minio","full_name":"krishnasrinivas/minio","owner":{"login":"krishnasrinivas","id":634494,"avatar_url":"https://avatars0.githubusercontent.com/u/634494?v=4","gravatar_id":"","url":"https://api.github.com/users/krishnasrinivas","html_url":"https://github.com/krishnasrinivas","followers_url":"https://api.github.com/users/krishnasrinivas/followers","following_url":"https://api.github.com/users/krishnasrinivas/following{/other_user}","gists_url":"https://api.github.com/users/krishnasrinivas/gists{/gist_id}","starred_url":"https://api.github.com/users/krishnasrinivas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krishnasrinivas/subscriptions","organizations_url":"https://api.github.com/users/krishnasrinivas/orgs","repos_url":"https://api.github.com/users/krishnasrinivas/repos","events_url":"https://api.github.com/users/krishnasrinivas/events{/privacy}","received_events_url":"https://api.github.com/users/krishnasrinivas/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/krishnasrinivas/minio","description":"Minio Cloud Storage Server","fork":true,"url":"https://api.github.com/repos/krishnasrinivas/minio","forks_url":"https://api.github.com/repos/krishnasrinivas/minio/forks","keys_url":"https://api.github.com/repos/krishnasrinivas/minio/keys{/key_id}","collaborators_url":"https://api.github.com/repos/krishnasrinivas/minio/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/krishnasrinivas/minio/teams","hooks_url":"https://api.github.com/repos/krishnasrinivas/minio/hooks","issue_events_url":"https://api.github.com/repos/krishnasrinivas/minio/issues/events{/number}","events_url":"https://api.github.com/repos/krishnasrinivas/minio/events","assignees_url":"https://api.github.com/repos/krishnasrinivas/minio/assignees{/user}","branches_url":"https://api.github.com/repos/krishnasrinivas/minio/branches{/branch}","tags_url":"https://api.github.com/repos/krishnasrinivas/minio/tags","blobs_url":"https://api.github.com/repos/krishnasrinivas/minio/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/krishnasrinivas/minio/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/krishnasrinivas/minio/git/refs{/sha}","trees_url":"https://api.github.com/repos/krishnasrinivas/minio/git/trees{/sha}","statuses_url":"https://api.github.com/repos/krishnasrinivas/minio/statuses/{sha}","languages_url":"https://api.github.com/repos/krishnasrinivas/minio/languages","stargazers_url":"https://api.github.com/repos/krishnasrinivas/minio/stargazers","contributors_url":"https://api.github.com/repos/krishnasrinivas/minio/contributors","subscribers_url":"https://api.github.com/repos/krishnasrinivas/minio/subscribers","subscription_url":"https://api.github.com/repos/krishnasrinivas/minio/subscription","commits_url":"https://api.github.com/repos/krishnasrinivas/minio/commits{/sha}","git_commits_url":"https://api.github.com/repos/krishnasrinivas/minio/git/commits{/sha}","comments_url":"https://api.github.com/repos/krishnasrinivas/minio/comments{/number}","issue_comment_url":"https://api.github.com/repos/krishnasrinivas/minio/issues/comments{/number}","contents_url":"https://api.github.com/repos/krishnasrinivas/minio/contents/{+path}","compare_url":"https://api.github.com/repos/krishnasrinivas/minio/compare/{base}...{head}","merges_url":"https://api.github.com/repos/krishnasrinivas/minio/merges","archive_url":"https://api.github.com/repos/krishnasrinivas/minio/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/krishnasrinivas/minio/downloads","issues_url":"https://api.github.com/repos/krishnasrinivas/minio/issues{/number}","pulls_url":"https://api.github.com/repos/krishnasrinivas/minio/pulls{/number}","milestones_url":"https://api.github.com/repos/krishnasrinivas/minio/milestones{/number}","notifications_url":"https://api.github.com/repos/krishnasrinivas/minio/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/krishnasrinivas/minio/labels{/name}","releases_url":"https://api.github.com/repos/krishnasrinivas/minio/releases{/id}","deployments_url":"https://api.github.com/repos/krishnasrinivas/minio/deployments","created_at":"2015-07-25T22:31:14Z","updated_at":"2017-10-25T03:49:30Z","pushed_at":"2018-04-26T21:26:43Z","git_url":"git://github.com/krishnasrinivas/minio.git","ssh_url":"git@github.com:krishnasrinivas/minio.git","clone_url":"https://github.com/krishnasrinivas/minio.git","svn_url":"https://github.com/krishnasrinivas/minio","homepage":"https://minio.io/#minio-server","size":37323,"stargazers_count":2,"watchers_count":2,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":1,"open_issues":0,"watchers":2,"default_branch":"master"}},"base":{"label":"minio:master","ref":"master","sha":"0dc3d7ac180505741bfff0cc64d9708771f91f91","user":{"login":"minio","id":695951,"avatar_url":"https://avatars3.githubusercontent.com/u/695951?v=4","gravatar_id":"","url":"https://api.github.com/users/minio","html_url":"https://github.com/minio","followers_url":"https://api.github.com/users/minio/followers","following_url":"https://api.github.com/users/minio/following{/other_user}","gists_url":"https://api.github.com/users/minio/gists{/gist_id}","starred_url":"https://api.github.com/users/minio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/minio/subscriptions","organizations_url":"https://api.github.com/users/minio/orgs","repos_url":"https://api.github.com/users/minio/repos","events_url":"https://api.github.com/users/minio/events{/privacy}","received_events_url":"https://api.github.com/users/minio/received_events","type":"Organization","site_admin":false},"repo":{"id":29261473,"name":"minio","full_name":"minio/minio","owner":{"login":"minio","id":695951,"avatar_url":"https://avatars3.githubusercontent.com/u/695951?v=4","gravatar_id":"","url":"https://api.github.com/users/minio","html_url":"https://github.com/minio","followers_url":"https://api.github.com/users/minio/followers","following_url":"https://api.github.com/users/minio/following{/other_user}","gists_url":"https://api.github.com/users/minio/gists{/gist_id}","starred_url":"https://api.github.com/users/minio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/minio/subscriptions","organizations_url":"https://api.github.com/users/minio/orgs","repos_url":"https://api.github.com/users/minio/repos","events_url":"https://api.github.com/users/minio/events{/privacy}","received_events_url":"https://api.github.com/users/minio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/minio/minio","description":"Minio is an open source object storage server compatible with Amazon S3 APIs","fork":false,"url":"https://api.github.com/repos/minio/minio","forks_url":"https://api.github.com/repos/minio/minio/forks","keys_url":"https://api.github.com/repos/minio/minio/keys{/key_id}","collaborators_url":"https://api.github.com/repos/minio/minio/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/minio/minio/teams","hooks_url":"https://api.github.com/repos/minio/minio/hooks","issue_events_url":"https://api.github.com/repos/minio/minio/issues/events{/number}","events_url":"https://api.github.com/repos/minio/minio/events","assignees_url":"https://api.github.com/repos/minio/minio/assignees{/user}","branches_url":"https://api.github.com/repos/minio/minio/branches{/branch}","tags_url":"https://api.github.com/repos/minio/minio/tags","blobs_url":"https://api.github.com/repos/minio/minio/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/minio/minio/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/minio/minio/git/refs{/sha}","trees_url":"https://api.github.com/repos/minio/minio/git/trees{/sha}","statuses_url":"https://api.github.com/repos/minio/minio/statuses/{sha}","languages_url":"https://api.github.com/repos/minio/minio/languages","stargazers_url":"https://api.github.com/repos/minio/minio/stargazers","contributors_url":"https://api.github.com/repos/minio/minio/contributors","subscribers_url":"https://api.github.com/repos/minio/minio/subscribers","subscription_url":"https://api.github.com/repos/minio/minio/subscription","commits_url":"https://api.github.com/repos/minio/minio/commits{/sha}","git_commits_url":"https://api.github.com/repos/minio/minio/git/commits{/sha}","comments_url":"https://api.github.com/repos/minio/minio/comments{/number}","issue_comment_url":"https://api.github.com/repos/minio/minio/issues/comments{/number}","contents_url":"https://api.github.com/repos/minio/minio/contents/{+path}","compare_url":"https://api.github.com/repos/minio/minio/compare/{base}...{head}","merges_url":"https://api.github.com/repos/minio/minio/merges","archive_url":"https://api.github.com/repos/minio/minio/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/minio/minio/downloads","issues_url":"https://api.github.com/repos/minio/minio/issues{/number}","pulls_url":"https://api.github.com/repos/minio/minio/pulls{/number}","milestones_url":"https://api.github.com/repos/minio/minio/milestones{/number}","notifications_url":"https://api.github.com/repos/minio/minio/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/minio/minio/labels{/name}","releases_url":"https://api.github.com/repos/minio/minio/releases{/id}","deployments_url":"https://api.github.com/repos/minio/minio/deployments","created_at":"2015-01-14T19:23:58Z","updated_at":"2018-04-27T15:28:30Z","pushed_at":"2018-04-27T15:28:24Z","git_url":"git://github.com/minio/minio.git","ssh_url":"git@github.com:minio/minio.git","clone_url":"https://github.com/minio/minio.git","svn_url":"https://github.com/minio/minio","homepage":"https://minio.io/downloads.html#download-server","size":35176,"stargazers_count":11110,"watchers_count":11110,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":941,"mirror_url":null,"archived":false,"open_issues_count":118,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":941,"open_issues":118,"watchers":11110,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/minio/minio/pulls/5856"},"html":{"href":"https://github.com/minio/minio/pull/5856"},"issue":{"href":"https://api.github.com/repos/minio/minio/issues/5856"},"comments":{"href":"https://api.github.com/repos/minio/minio/issues/5856/comments"},"review_comments":{"href":"https://api.github.com/repos/minio/minio/pulls/5856/comments"},"review_comment":{"href":"https://api.github.com/repos/minio/minio/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/minio/minio/pulls/5856/commits"},"statuses":{"href":"https://api.github.com/repos/minio/minio/statuses/71406aabf31127b09b16ddf00c7c2b05d6767d9a"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"harshavardhana"}}