{"action":"created","comment":{"url":"https://api.github.com/repos/ceph/ceph/pulls/comments/59742543","id":59742543,"diff_hunk":"@@ -1334,6 +1334,24 @@ CEPH_RADOS_API int rados_write_full(rados_ioctx_t io, const char *oid,\n                                     const char *buf, size_t len);\n \n /**\n+ * Write the same *data_len* bytes from *buf* multiple times into the\n+ * *oid* object. *write_len* bytes are written in total, which must be\n+ * a multiple of *data_len*. The value of *write_len* and *data_len*\n+ * must be <= UINT_MAX/2.\n+ *\n+ * @param io the io context in which the write will occur\n+ * @param oid name of the object\n+ * @param buf data to write\n+ * @param data_len length of the data, in bytes\n+ * @param write_len the total number of bytes to write\n+ * @param off byte offset in the object to begin writing at\n+ * @returns 0 on success, negative error code on failure\n+ */\n+CEPH_RADOS_API int rados_writesame(rados_ioctx_t io, const char *oid,\n+                                   const char *buf, size_t data_len,\n+                                   size_t write_len, uint64_t off);","path":"src/include/rados/librados.h","position":30,"original_position":30,"commit_id":"b62575b9b9a4cc79ff7d3fc53aee3ab18f1bbced","original_commit_id":"b62575b9b9a4cc79ff7d3fc53aee3ab18f1bbced","user":{"login":"jdurgin","id":1022584,"avatar_url":"https://avatars.githubusercontent.com/u/1022584?v=3","gravatar_id":"","url":"https://api.github.com/users/jdurgin","html_url":"https://github.com/jdurgin","followers_url":"https://api.github.com/users/jdurgin/followers","following_url":"https://api.github.com/users/jdurgin/following{/other_user}","gists_url":"https://api.github.com/users/jdurgin/gists{/gist_id}","starred_url":"https://api.github.com/users/jdurgin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdurgin/subscriptions","organizations_url":"https://api.github.com/users/jdurgin/orgs","repos_url":"https://api.github.com/users/jdurgin/repos","events_url":"https://api.github.com/users/jdurgin/events{/privacy}","received_events_url":"https://api.github.com/users/jdurgin/received_events","type":"User","site_admin":false},"body":"If you think we might drop the alignment requirement I'd leave the api as-is, so we don't need a new version of the function to handle that","created_at":"2016-04-14T15:54:34Z","updated_at":"2016-04-14T15:54:34Z","html_url":"https://github.com/ceph/ceph/pull/8568#discussion_r59742543","pull_request_url":"https://api.github.com/repos/ceph/ceph/pulls/8568","_links":{"self":{"href":"https://api.github.com/repos/ceph/ceph/pulls/comments/59742543"},"html":{"href":"https://github.com/ceph/ceph/pull/8568#discussion_r59742543"},"pull_request":{"href":"https://api.github.com/repos/ceph/ceph/pulls/8568"}}},"pull_request":{"url":"https://api.github.com/repos/ceph/ceph/pulls/8568","id":66250807,"html_url":"https://github.com/ceph/ceph/pull/8568","diff_url":"https://github.com/ceph/ceph/pull/8568.diff","patch_url":"https://github.com/ceph/ceph/pull/8568.patch","issue_url":"https://api.github.com/repos/ceph/ceph/issues/8568","number":8568,"state":"open","locked":false,"title":"OSD and librados writesame support","user":{"login":"ddiss","id":3995472,"avatar_url":"https://avatars.githubusercontent.com/u/3995472?v=3","gravatar_id":"","url":"https://api.github.com/users/ddiss","html_url":"https://github.com/ddiss","followers_url":"https://api.github.com/users/ddiss/followers","following_url":"https://api.github.com/users/ddiss/following{/other_user}","gists_url":"https://api.github.com/users/ddiss/gists{/gist_id}","starred_url":"https://api.github.com/users/ddiss/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ddiss/subscriptions","organizations_url":"https://api.github.com/users/ddiss/orgs","repos_url":"https://api.github.com/users/ddiss/repos","events_url":"https://api.github.com/users/ddiss/events{/privacy}","received_events_url":"https://api.github.com/users/ddiss/received_events","type":"User","site_admin":false},"body":"This is a follow up to https://github.com/ceph/ceph/pull/8175 , which adds a librados API and tests atop the OSD writesame implementation from @mikechristie. I'll submit the cmpext support separately.\r\nA few things potentially worth changing:\r\n- allow for librados zero-length writesame requests\r\n- use .*write_same() instead of *writesame(), to be consistent with write_full()\r\n- add librados striper API and tests (?)","created_at":"2016-04-13T00:45:56Z","updated_at":"2016-04-14T15:54:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c3c7dd8a45c87383d198f7909a049ea5f3c1344b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ceph/ceph/pulls/8568/commits","review_comments_url":"https://api.github.com/repos/ceph/ceph/pulls/8568/comments","review_comment_url":"https://api.github.com/repos/ceph/ceph/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ceph/ceph/issues/8568/comments","statuses_url":"https://api.github.com/repos/ceph/ceph/statuses/b62575b9b9a4cc79ff7d3fc53aee3ab18f1bbced","head":{"label":"ddiss:osd-librados-writesame","ref":"osd-librados-writesame","sha":"b62575b9b9a4cc79ff7d3fc53aee3ab18f1bbced","user":{"login":"ddiss","id":3995472,"avatar_url":"https://avatars.githubusercontent.com/u/3995472?v=3","gravatar_id":"","url":"https://api.github.com/users/ddiss","html_url":"https://github.com/ddiss","followers_url":"https://api.github.com/users/ddiss/followers","following_url":"https://api.github.com/users/ddiss/following{/other_user}","gists_url":"https://api.github.com/users/ddiss/gists{/gist_id}","starred_url":"https://api.github.com/users/ddiss/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ddiss/subscriptions","organizations_url":"https://api.github.com/users/ddiss/orgs","repos_url":"https://api.github.com/users/ddiss/repos","events_url":"https://api.github.com/users/ddiss/events{/privacy}","received_events_url":"https://api.github.com/users/ddiss/received_events","type":"User","site_admin":false},"repo":{"id":11739533,"name":"ceph","full_name":"ddiss/ceph","owner":{"login":"ddiss","id":3995472,"avatar_url":"https://avatars.githubusercontent.com/u/3995472?v=3","gravatar_id":"","url":"https://api.github.com/users/ddiss","html_url":"https://github.com/ddiss","followers_url":"https://api.github.com/users/ddiss/followers","following_url":"https://api.github.com/users/ddiss/following{/other_user}","gists_url":"https://api.github.com/users/ddiss/gists{/gist_id}","starred_url":"https://api.github.com/users/ddiss/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ddiss/subscriptions","organizations_url":"https://api.github.com/users/ddiss/orgs","repos_url":"https://api.github.com/users/ddiss/repos","events_url":"https://api.github.com/users/ddiss/events{/privacy}","received_events_url":"https://api.github.com/users/ddiss/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ddiss/ceph","description":"Ceph is a distributed object, block, and file storage platform ","fork":true,"url":"https://api.github.com/repos/ddiss/ceph","forks_url":"https://api.github.com/repos/ddiss/ceph/forks","keys_url":"https://api.github.com/repos/ddiss/ceph/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ddiss/ceph/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ddiss/ceph/teams","hooks_url":"https://api.github.com/repos/ddiss/ceph/hooks","issue_events_url":"https://api.github.com/repos/ddiss/ceph/issues/events{/number}","events_url":"https://api.github.com/repos/ddiss/ceph/events","assignees_url":"https://api.github.com/repos/ddiss/ceph/assignees{/user}","branches_url":"https://api.github.com/repos/ddiss/ceph/branches{/branch}","tags_url":"https://api.github.com/repos/ddiss/ceph/tags","blobs_url":"https://api.github.com/repos/ddiss/ceph/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ddiss/ceph/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ddiss/ceph/git/refs{/sha}","trees_url":"https://api.github.com/repos/ddiss/ceph/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ddiss/ceph/statuses/{sha}","languages_url":"https://api.github.com/repos/ddiss/ceph/languages","stargazers_url":"https://api.github.com/repos/ddiss/ceph/stargazers","contributors_url":"https://api.github.com/repos/ddiss/ceph/contributors","subscribers_url":"https://api.github.com/repos/ddiss/ceph/subscribers","subscription_url":"https://api.github.com/repos/ddiss/ceph/subscription","commits_url":"https://api.github.com/repos/ddiss/ceph/commits{/sha}","git_commits_url":"https://api.github.com/repos/ddiss/ceph/git/commits{/sha}","comments_url":"https://api.github.com/repos/ddiss/ceph/comments{/number}","issue_comment_url":"https://api.github.com/repos/ddiss/ceph/issues/comments{/number}","contents_url":"https://api.github.com/repos/ddiss/ceph/contents/{+path}","compare_url":"https://api.github.com/repos/ddiss/ceph/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ddiss/ceph/merges","archive_url":"https://api.github.com/repos/ddiss/ceph/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ddiss/ceph/downloads","issues_url":"https://api.github.com/repos/ddiss/ceph/issues{/number}","pulls_url":"https://api.github.com/repos/ddiss/ceph/pulls{/number}","milestones_url":"https://api.github.com/repos/ddiss/ceph/milestones{/number}","notifications_url":"https://api.github.com/repos/ddiss/ceph/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ddiss/ceph/labels{/name}","releases_url":"https://api.github.com/repos/ddiss/ceph/releases{/id}","deployments_url":"https://api.github.com/repos/ddiss/ceph/deployments","created_at":"2013-07-29T12:53:53Z","updated_at":"2016-01-26T00:17:42Z","pushed_at":"2016-04-13T00:17:33Z","git_url":"git://github.com/ddiss/ceph.git","ssh_url":"git@github.com:ddiss/ceph.git","clone_url":"https://github.com/ddiss/ceph.git","svn_url":"https://github.com/ddiss/ceph","homepage":"http://ceph.com","size":235187,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ceph:master","ref":"master","sha":"18a5fddb90d180315e1817c0f7341101636408b2","user":{"login":"ceph","id":1015767,"avatar_url":"https://avatars.githubusercontent.com/u/1015767?v=3","gravatar_id":"","url":"https://api.github.com/users/ceph","html_url":"https://github.com/ceph","followers_url":"https://api.github.com/users/ceph/followers","following_url":"https://api.github.com/users/ceph/following{/other_user}","gists_url":"https://api.github.com/users/ceph/gists{/gist_id}","starred_url":"https://api.github.com/users/ceph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ceph/subscriptions","organizations_url":"https://api.github.com/users/ceph/orgs","repos_url":"https://api.github.com/users/ceph/repos","events_url":"https://api.github.com/users/ceph/events{/privacy}","received_events_url":"https://api.github.com/users/ceph/received_events","type":"Organization","site_admin":false},"repo":{"id":2310495,"name":"ceph","full_name":"ceph/ceph","owner":{"login":"ceph","id":1015767,"avatar_url":"https://avatars.githubusercontent.com/u/1015767?v=3","gravatar_id":"","url":"https://api.github.com/users/ceph","html_url":"https://github.com/ceph","followers_url":"https://api.github.com/users/ceph/followers","following_url":"https://api.github.com/users/ceph/following{/other_user}","gists_url":"https://api.github.com/users/ceph/gists{/gist_id}","starred_url":"https://api.github.com/users/ceph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ceph/subscriptions","organizations_url":"https://api.github.com/users/ceph/orgs","repos_url":"https://api.github.com/users/ceph/repos","events_url":"https://api.github.com/users/ceph/events{/privacy}","received_events_url":"https://api.github.com/users/ceph/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ceph/ceph","description":"Ceph is a distributed object, block, and file storage platform ","fork":false,"url":"https://api.github.com/repos/ceph/ceph","forks_url":"https://api.github.com/repos/ceph/ceph/forks","keys_url":"https://api.github.com/repos/ceph/ceph/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ceph/ceph/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ceph/ceph/teams","hooks_url":"https://api.github.com/repos/ceph/ceph/hooks","issue_events_url":"https://api.github.com/repos/ceph/ceph/issues/events{/number}","events_url":"https://api.github.com/repos/ceph/ceph/events","assignees_url":"https://api.github.com/repos/ceph/ceph/assignees{/user}","branches_url":"https://api.github.com/repos/ceph/ceph/branches{/branch}","tags_url":"https://api.github.com/repos/ceph/ceph/tags","blobs_url":"https://api.github.com/repos/ceph/ceph/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ceph/ceph/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ceph/ceph/git/refs{/sha}","trees_url":"https://api.github.com/repos/ceph/ceph/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ceph/ceph/statuses/{sha}","languages_url":"https://api.github.com/repos/ceph/ceph/languages","stargazers_url":"https://api.github.com/repos/ceph/ceph/stargazers","contributors_url":"https://api.github.com/repos/ceph/ceph/contributors","subscribers_url":"https://api.github.com/repos/ceph/ceph/subscribers","subscription_url":"https://api.github.com/repos/ceph/ceph/subscription","commits_url":"https://api.github.com/repos/ceph/ceph/commits{/sha}","git_commits_url":"https://api.github.com/repos/ceph/ceph/git/commits{/sha}","comments_url":"https://api.github.com/repos/ceph/ceph/comments{/number}","issue_comment_url":"https://api.github.com/repos/ceph/ceph/issues/comments{/number}","contents_url":"https://api.github.com/repos/ceph/ceph/contents/{+path}","compare_url":"https://api.github.com/repos/ceph/ceph/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ceph/ceph/merges","archive_url":"https://api.github.com/repos/ceph/ceph/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ceph/ceph/downloads","issues_url":"https://api.github.com/repos/ceph/ceph/issues{/number}","pulls_url":"https://api.github.com/repos/ceph/ceph/pulls{/number}","milestones_url":"https://api.github.com/repos/ceph/ceph/milestones{/number}","notifications_url":"https://api.github.com/repos/ceph/ceph/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ceph/ceph/labels{/name}","releases_url":"https://api.github.com/repos/ceph/ceph/releases{/id}","deployments_url":"https://api.github.com/repos/ceph/ceph/deployments","created_at":"2011-09-01T21:41:26Z","updated_at":"2016-04-14T08:35:32Z","pushed_at":"2016-04-14T15:39:48Z","git_url":"git://github.com/ceph/ceph.git","ssh_url":"git@github.com:ceph/ceph.git","clone_url":"https://github.com/ceph/ceph.git","svn_url":"https://github.com/ceph/ceph","homepage":"http://ceph.com","size":212978,"stargazers_count":2053,"watchers_count":2053,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1225,"mirror_url":null,"open_issues_count":352,"forks":1225,"open_issues":352,"watchers":2053,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ceph/ceph/pulls/8568"},"html":{"href":"https://github.com/ceph/ceph/pull/8568"},"issue":{"href":"https://api.github.com/repos/ceph/ceph/issues/8568"},"comments":{"href":"https://api.github.com/repos/ceph/ceph/issues/8568/comments"},"review_comments":{"href":"https://api.github.com/repos/ceph/ceph/pulls/8568/comments"},"review_comment":{"href":"https://api.github.com/repos/ceph/ceph/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ceph/ceph/pulls/8568/commits"},"statuses":{"href":"https://api.github.com/repos/ceph/ceph/statuses/b62575b9b9a4cc79ff7d3fc53aee3ab18f1bbced"}}}}