{"action":"created","comment":{"url":"https://api.github.com/repos/genome/genome/pulls/comments/26118538","id":26118538,"diff_hunk":"@@ -1190,4 +1190,22 @@ sub expunge {\n     return 1;\n }\n \n+sub resize_disk_allocation {\n+    my $self = shift;\n+    my %params = @_;\n+\n+    $self->debug_message(\"Resizing the disk allocation...\");\n+\n+    # The property is technically is_many but I believe this would break a lot of things in practice\n+    if ($self->disk_allocations) {\n+        $params{allow_reallocate_with_move} = 0;\n+        $params{allow_reallocate_with_move} = 1 if $self->disk_allocations->kilobytes_requested < 10_485_760; # 10GB\n+        unless (eval { $self->disk_allocations->reallocate(%params) }) {\n+            $self->warning_message(\"Failed to reallocate my disk allocation with id (%s). Eval returned (%s) \", $self->disk_allocations->id, $@);\n+        }\n+        $self->output_dir($self->disk_allocations->absolute_path); #update if was moved","path":"lib/perl/Genome/SoftwareResult.pm","position":17,"original_position":17,"commit_id":"b09e1611f2558466a8dd2fb415051d574fc189ad","original_commit_id":"b09e1611f2558466a8dd2fb415051d574fc189ad","user":{"login":"tmooney","id":187262,"avatar_url":"https://avatars.githubusercontent.com/u/187262?v=3","gravatar_id":"","url":"https://api.github.com/users/tmooney","html_url":"https://github.com/tmooney","followers_url":"https://api.github.com/users/tmooney/followers","following_url":"https://api.github.com/users/tmooney/following{/other_user}","gists_url":"https://api.github.com/users/tmooney/gists{/gist_id}","starred_url":"https://api.github.com/users/tmooney/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tmooney/subscriptions","organizations_url":"https://api.github.com/users/tmooney/orgs","repos_url":"https://api.github.com/users/tmooney/repos","events_url":"https://api.github.com/users/tmooney/events{/privacy}","received_events_url":"https://api.github.com/users/tmooney/received_events","type":"User","site_admin":false},"body":"This line is handled by `Genome::Disk::Allocation::_update_owner_for_move` now.","created_at":"2015-03-10T12:57:02Z","updated_at":"2015-03-10T12:57:02Z","html_url":"https://github.com/genome/genome/pull/407#discussion_r26118538","pull_request_url":"https://api.github.com/repos/genome/genome/pulls/407","_links":{"self":{"href":"https://api.github.com/repos/genome/genome/pulls/comments/26118538"},"html":{"href":"https://github.com/genome/genome/pull/407#discussion_r26118538"},"pull_request":{"href":"https://api.github.com/repos/genome/genome/pulls/407"}}},"pull_request":{"url":"https://api.github.com/repos/genome/genome/pulls/407","id":27306488,"html_url":"https://github.com/genome/genome/pull/407","diff_url":"https://github.com/genome/genome/pull/407.diff","patch_url":"https://github.com/genome/genome/pull/407.patch","issue_url":"https://api.github.com/repos/genome/genome/issues/407","number":407,"state":"open","locked":false,"title":"Recreate per-lane bams on demand (and delete them when done)","user":{"login":"gsanders","id":863032,"avatar_url":"https://avatars.githubusercontent.com/u/863032?v=3","gravatar_id":"","url":"https://api.github.com/users/gsanders","html_url":"https://github.com/gsanders","followers_url":"https://api.github.com/users/gsanders/followers","following_url":"https://api.github.com/users/gsanders/following{/other_user}","gists_url":"https://api.github.com/users/gsanders/gists{/gist_id}","starred_url":"https://api.github.com/users/gsanders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gsanders/subscriptions","organizations_url":"https://api.github.com/users/gsanders/orgs","repos_url":"https://api.github.com/users/gsanders/repos","events_url":"https://api.github.com/users/gsanders/events{/privacy}","received_events_url":"https://api.github.com/users/gsanders/received_events","type":"User","site_admin":false},"body":"This PR is to begin the discussion on the deletion and recreation of per-lane bams as appropriate. It's quite possible we are not locking enough and race conditions exist. I'm also sure we could use some code cleanup. We could use a lot of help with both of these things!\r\n\r\nWe are creating a 'real world one-off' integration test, which will a model with two builds. In the first build we will have two instrument data. In the third build we will delete the bams for the first two instrument data and archive the merged bam. The second build should unarchive the merged bam, recreate the two per-lane bams, align the third instrument data, and merge it all. If this works we'll have some confidence that we are doing what is required, but I'd still want to give a long look into locking and race condition issues.","created_at":"2015-01-13T21:30:32Z","updated_at":"2015-03-10T12:57:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"11df4c4980ffb7e3e1b20d6387e4849abb998a23","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/genome/genome/pulls/407/commits","review_comments_url":"https://api.github.com/repos/genome/genome/pulls/407/comments","review_comment_url":"https://api.github.com/repos/genome/genome/pulls/comments{/number}","comments_url":"https://api.github.com/repos/genome/genome/issues/407/comments","statuses_url":"https://api.github.com/repos/genome/genome/statuses/b09e1611f2558466a8dd2fb415051d574fc189ad","head":{"label":"gsanders:recreate_per_lane_bam","ref":"recreate_per_lane_bam","sha":"b09e1611f2558466a8dd2fb415051d574fc189ad","user":{"login":"gsanders","id":863032,"avatar_url":"https://avatars.githubusercontent.com/u/863032?v=3","gravatar_id":"","url":"https://api.github.com/users/gsanders","html_url":"https://github.com/gsanders","followers_url":"https://api.github.com/users/gsanders/followers","following_url":"https://api.github.com/users/gsanders/following{/other_user}","gists_url":"https://api.github.com/users/gsanders/gists{/gist_id}","starred_url":"https://api.github.com/users/gsanders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gsanders/subscriptions","organizations_url":"https://api.github.com/users/gsanders/orgs","repos_url":"https://api.github.com/users/gsanders/repos","events_url":"https://api.github.com/users/gsanders/events{/privacy}","received_events_url":"https://api.github.com/users/gsanders/received_events","type":"User","site_admin":false},"repo":{"id":23676692,"name":"genome","full_name":"gsanders/genome","owner":{"login":"gsanders","id":863032,"avatar_url":"https://avatars.githubusercontent.com/u/863032?v=3","gravatar_id":"","url":"https://api.github.com/users/gsanders","html_url":"https://github.com/gsanders","followers_url":"https://api.github.com/users/gsanders/followers","following_url":"https://api.github.com/users/gsanders/following{/other_user}","gists_url":"https://api.github.com/users/gsanders/gists{/gist_id}","starred_url":"https://api.github.com/users/gsanders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gsanders/subscriptions","organizations_url":"https://api.github.com/users/gsanders/orgs","repos_url":"https://api.github.com/users/gsanders/repos","events_url":"https://api.github.com/users/gsanders/events{/privacy}","received_events_url":"https://api.github.com/users/gsanders/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gsanders/genome","description":"","fork":true,"url":"https://api.github.com/repos/gsanders/genome","forks_url":"https://api.github.com/repos/gsanders/genome/forks","keys_url":"https://api.github.com/repos/gsanders/genome/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gsanders/genome/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gsanders/genome/teams","hooks_url":"https://api.github.com/repos/gsanders/genome/hooks","issue_events_url":"https://api.github.com/repos/gsanders/genome/issues/events{/number}","events_url":"https://api.github.com/repos/gsanders/genome/events","assignees_url":"https://api.github.com/repos/gsanders/genome/assignees{/user}","branches_url":"https://api.github.com/repos/gsanders/genome/branches{/branch}","tags_url":"https://api.github.com/repos/gsanders/genome/tags","blobs_url":"https://api.github.com/repos/gsanders/genome/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gsanders/genome/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gsanders/genome/git/refs{/sha}","trees_url":"https://api.github.com/repos/gsanders/genome/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gsanders/genome/statuses/{sha}","languages_url":"https://api.github.com/repos/gsanders/genome/languages","stargazers_url":"https://api.github.com/repos/gsanders/genome/stargazers","contributors_url":"https://api.github.com/repos/gsanders/genome/contributors","subscribers_url":"https://api.github.com/repos/gsanders/genome/subscribers","subscription_url":"https://api.github.com/repos/gsanders/genome/subscription","commits_url":"https://api.github.com/repos/gsanders/genome/commits{/sha}","git_commits_url":"https://api.github.com/repos/gsanders/genome/git/commits{/sha}","comments_url":"https://api.github.com/repos/gsanders/genome/comments{/number}","issue_comment_url":"https://api.github.com/repos/gsanders/genome/issues/comments{/number}","contents_url":"https://api.github.com/repos/gsanders/genome/contents/{+path}","compare_url":"https://api.github.com/repos/gsanders/genome/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gsanders/genome/merges","archive_url":"https://api.github.com/repos/gsanders/genome/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gsanders/genome/downloads","issues_url":"https://api.github.com/repos/gsanders/genome/issues{/number}","pulls_url":"https://api.github.com/repos/gsanders/genome/pulls{/number}","milestones_url":"https://api.github.com/repos/gsanders/genome/milestones{/number}","notifications_url":"https://api.github.com/repos/gsanders/genome/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gsanders/genome/labels{/name}","releases_url":"https://api.github.com/repos/gsanders/genome/releases{/id}","created_at":"2014-09-04T19:41:57Z","updated_at":"2014-09-04T19:44:39Z","pushed_at":"2015-03-09T22:05:57Z","git_url":"git://github.com/gsanders/genome.git","ssh_url":"git@github.com:gsanders/genome.git","clone_url":"https://github.com/gsanders/genome.git","svn_url":"https://github.com/gsanders/genome","homepage":"","size":112342,"stargazers_count":0,"watchers_count":0,"language":"Perl","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":"genome:master","ref":"master","sha":"67cfd1cc1ce23d5c0de01ae43a493d61e262025c","user":{"login":"genome","id":318108,"avatar_url":"https://avatars.githubusercontent.com/u/318108?v=3","gravatar_id":"","url":"https://api.github.com/users/genome","html_url":"https://github.com/genome","followers_url":"https://api.github.com/users/genome/followers","following_url":"https://api.github.com/users/genome/following{/other_user}","gists_url":"https://api.github.com/users/genome/gists{/gist_id}","starred_url":"https://api.github.com/users/genome/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/genome/subscriptions","organizations_url":"https://api.github.com/users/genome/orgs","repos_url":"https://api.github.com/users/genome/repos","events_url":"https://api.github.com/users/genome/events{/privacy}","received_events_url":"https://api.github.com/users/genome/received_events","type":"Organization","site_admin":false},"repo":{"id":23442737,"name":"genome","full_name":"genome/genome","owner":{"login":"genome","id":318108,"avatar_url":"https://avatars.githubusercontent.com/u/318108?v=3","gravatar_id":"","url":"https://api.github.com/users/genome","html_url":"https://github.com/genome","followers_url":"https://api.github.com/users/genome/followers","following_url":"https://api.github.com/users/genome/following{/other_user}","gists_url":"https://api.github.com/users/genome/gists{/gist_id}","starred_url":"https://api.github.com/users/genome/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/genome/subscriptions","organizations_url":"https://api.github.com/users/genome/orgs","repos_url":"https://api.github.com/users/genome/repos","events_url":"https://api.github.com/users/genome/events{/privacy}","received_events_url":"https://api.github.com/users/genome/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/genome/genome","description":"Core modules used by the GMS","fork":false,"url":"https://api.github.com/repos/genome/genome","forks_url":"https://api.github.com/repos/genome/genome/forks","keys_url":"https://api.github.com/repos/genome/genome/keys{/key_id}","collaborators_url":"https://api.github.com/repos/genome/genome/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/genome/genome/teams","hooks_url":"https://api.github.com/repos/genome/genome/hooks","issue_events_url":"https://api.github.com/repos/genome/genome/issues/events{/number}","events_url":"https://api.github.com/repos/genome/genome/events","assignees_url":"https://api.github.com/repos/genome/genome/assignees{/user}","branches_url":"https://api.github.com/repos/genome/genome/branches{/branch}","tags_url":"https://api.github.com/repos/genome/genome/tags","blobs_url":"https://api.github.com/repos/genome/genome/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/genome/genome/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/genome/genome/git/refs{/sha}","trees_url":"https://api.github.com/repos/genome/genome/git/trees{/sha}","statuses_url":"https://api.github.com/repos/genome/genome/statuses/{sha}","languages_url":"https://api.github.com/repos/genome/genome/languages","stargazers_url":"https://api.github.com/repos/genome/genome/stargazers","contributors_url":"https://api.github.com/repos/genome/genome/contributors","subscribers_url":"https://api.github.com/repos/genome/genome/subscribers","subscription_url":"https://api.github.com/repos/genome/genome/subscription","commits_url":"https://api.github.com/repos/genome/genome/commits{/sha}","git_commits_url":"https://api.github.com/repos/genome/genome/git/commits{/sha}","comments_url":"https://api.github.com/repos/genome/genome/comments{/number}","issue_comment_url":"https://api.github.com/repos/genome/genome/issues/comments{/number}","contents_url":"https://api.github.com/repos/genome/genome/contents/{+path}","compare_url":"https://api.github.com/repos/genome/genome/compare/{base}...{head}","merges_url":"https://api.github.com/repos/genome/genome/merges","archive_url":"https://api.github.com/repos/genome/genome/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/genome/genome/downloads","issues_url":"https://api.github.com/repos/genome/genome/issues{/number}","pulls_url":"https://api.github.com/repos/genome/genome/pulls{/number}","milestones_url":"https://api.github.com/repos/genome/genome/milestones{/number}","notifications_url":"https://api.github.com/repos/genome/genome/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/genome/genome/labels{/name}","releases_url":"https://api.github.com/repos/genome/genome/releases{/id}","created_at":"2014-08-28T20:59:19Z","updated_at":"2015-03-09T22:38:40Z","pushed_at":"2015-03-10T03:10:41Z","git_url":"git://github.com/genome/genome.git","ssh_url":"git@github.com:genome/genome.git","clone_url":"https://github.com/genome/genome.git","svn_url":"https://github.com/genome/genome","homepage":"","size":125302,"stargazers_count":6,"watchers_count":6,"language":"Perl","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":35,"mirror_url":null,"open_issues_count":15,"forks":35,"open_issues":15,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/genome/genome/pulls/407"},"html":{"href":"https://github.com/genome/genome/pull/407"},"issue":{"href":"https://api.github.com/repos/genome/genome/issues/407"},"comments":{"href":"https://api.github.com/repos/genome/genome/issues/407/comments"},"review_comments":{"href":"https://api.github.com/repos/genome/genome/pulls/407/comments"},"review_comment":{"href":"https://api.github.com/repos/genome/genome/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/genome/genome/pulls/407/commits"},"statuses":{"href":"https://api.github.com/repos/genome/genome/statuses/b09e1611f2558466a8dd2fb415051d574fc189ad"}}}}