{"action":"created","comment":{"url":"https://api.github.com/repos/treehouse/timberline/pulls/comments/54039851","id":54039851,"diff_hunk":"@@ -88,4 +88,34 @@\n       expect(envelope.fritters).to eq \"the bacon kind\"\n     end\n   end\n+\n+  describe \"#operate_later?\" do\n+    let(:base_data_hash) { { contents: \"test content\" }}","path":"spec/lib/timberline/envelope_spec.rb","position":6,"original_position":6,"commit_id":"e9021f23e53276ca6bb3bbbcff5064935df66eb1","original_commit_id":"e9021f23e53276ca6bb3bbbcff5064935df66eb1","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Space missing inside }.","created_at":"2016-02-25T02:07:39Z","updated_at":"2016-02-25T02:07:39Z","html_url":"https://github.com/treehouse/timberline/pull/15#discussion_r54039851","pull_request_url":"https://api.github.com/repos/treehouse/timberline/pulls/15","_links":{"self":{"href":"https://api.github.com/repos/treehouse/timberline/pulls/comments/54039851"},"html":{"href":"https://github.com/treehouse/timberline/pull/15#discussion_r54039851"},"pull_request":{"href":"https://api.github.com/repos/treehouse/timberline/pulls/15"}}},"pull_request":{"url":"https://api.github.com/repos/treehouse/timberline/pulls/15","id":60613469,"html_url":"https://github.com/treehouse/timberline/pull/15","diff_url":"https://github.com/treehouse/timberline/pull/15.diff","patch_url":"https://github.com/treehouse/timberline/pull/15.patch","issue_url":"https://api.github.com/repos/treehouse/timberline/issues/15","number":15,"state":"open","locked":false,"title":"Delayed Envelope Opening","user":{"login":"janxious","id":50124,"avatar_url":"https://avatars.githubusercontent.com/u/50124?v=3","gravatar_id":"","url":"https://api.github.com/users/janxious","html_url":"https://github.com/janxious","followers_url":"https://api.github.com/users/janxious/followers","following_url":"https://api.github.com/users/janxious/following{/other_user}","gists_url":"https://api.github.com/users/janxious/gists{/gist_id}","starred_url":"https://api.github.com/users/janxious/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janxious/subscriptions","organizations_url":"https://api.github.com/users/janxious/orgs","repos_url":"https://api.github.com/users/janxious/repos","events_url":"https://api.github.com/users/janxious/events{/privacy}","received_events_url":"https://api.github.com/users/janxious/received_events","type":"User","site_admin":false},"body":"## Why\r\n\r\nWas chatting with @aimee-ault about ActiveJob integration and lack of support for enqueuing jobs for later execution. So this is a first stab because I was curious.\r\n\r\n## What\r\n\r\n* Bump RSpec to latest (this is easy to cherry pick)\r\n* Added a dequeue-enqueue step before job execution in the worker loop\r\n\r\n## Additional\r\n\r\n[This bit](https://github.com/treehouse/timberline-rails/blob/master/lib/active_job/queue_adapters/timberline_adapter.rb#L12) in the active job adapter is going to have to change. Probably to something like:\r\n\r\n```ruby\r\ndef enqueue_at(job, timestamp)\r\n  Timberline.push job.queue_name, job.serialize, run_at: timestamp\r\nend\r\n```\r\n\r\n## Caveats\r\n\r\nI haven't ever run timberline, so this might be a terrible approach. Certainly it might cause a lot of redis churn. The mechanism by which the jobs are re-enqueued is not going to be handled by the various error catchers below the definition, so maybe there needs to be another layer there, or the code needs to be refactored to do the dequeueing inside a rescue block.","created_at":"2016-02-25T02:07:36Z","updated_at":"2016-02-25T02:07:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"39d30bfca07231a0a5c224d051914be7825cfa0a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/treehouse/timberline/pulls/15/commits","review_comments_url":"https://api.github.com/repos/treehouse/timberline/pulls/15/comments","review_comment_url":"https://api.github.com/repos/treehouse/timberline/pulls/comments{/number}","comments_url":"https://api.github.com/repos/treehouse/timberline/issues/15/comments","statuses_url":"https://api.github.com/repos/treehouse/timberline/statuses/e9021f23e53276ca6bb3bbbcff5064935df66eb1","head":{"label":"janxious:delayed-queue","ref":"delayed-queue","sha":"e9021f23e53276ca6bb3bbbcff5064935df66eb1","user":{"login":"janxious","id":50124,"avatar_url":"https://avatars.githubusercontent.com/u/50124?v=3","gravatar_id":"","url":"https://api.github.com/users/janxious","html_url":"https://github.com/janxious","followers_url":"https://api.github.com/users/janxious/followers","following_url":"https://api.github.com/users/janxious/following{/other_user}","gists_url":"https://api.github.com/users/janxious/gists{/gist_id}","starred_url":"https://api.github.com/users/janxious/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janxious/subscriptions","organizations_url":"https://api.github.com/users/janxious/orgs","repos_url":"https://api.github.com/users/janxious/repos","events_url":"https://api.github.com/users/janxious/events{/privacy}","received_events_url":"https://api.github.com/users/janxious/received_events","type":"User","site_admin":false},"repo":{"id":52484969,"name":"timberline","full_name":"janxious/timberline","owner":{"login":"janxious","id":50124,"avatar_url":"https://avatars.githubusercontent.com/u/50124?v=3","gravatar_id":"","url":"https://api.github.com/users/janxious","html_url":"https://github.com/janxious","followers_url":"https://api.github.com/users/janxious/followers","following_url":"https://api.github.com/users/janxious/following{/other_user}","gists_url":"https://api.github.com/users/janxious/gists{/gist_id}","starred_url":"https://api.github.com/users/janxious/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janxious/subscriptions","organizations_url":"https://api.github.com/users/janxious/orgs","repos_url":"https://api.github.com/users/janxious/repos","events_url":"https://api.github.com/users/janxious/events{/privacy}","received_events_url":"https://api.github.com/users/janxious/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/janxious/timberline","description":"Simple, extensible queuing in Ruby with Redis.","fork":true,"url":"https://api.github.com/repos/janxious/timberline","forks_url":"https://api.github.com/repos/janxious/timberline/forks","keys_url":"https://api.github.com/repos/janxious/timberline/keys{/key_id}","collaborators_url":"https://api.github.com/repos/janxious/timberline/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/janxious/timberline/teams","hooks_url":"https://api.github.com/repos/janxious/timberline/hooks","issue_events_url":"https://api.github.com/repos/janxious/timberline/issues/events{/number}","events_url":"https://api.github.com/repos/janxious/timberline/events","assignees_url":"https://api.github.com/repos/janxious/timberline/assignees{/user}","branches_url":"https://api.github.com/repos/janxious/timberline/branches{/branch}","tags_url":"https://api.github.com/repos/janxious/timberline/tags","blobs_url":"https://api.github.com/repos/janxious/timberline/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/janxious/timberline/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/janxious/timberline/git/refs{/sha}","trees_url":"https://api.github.com/repos/janxious/timberline/git/trees{/sha}","statuses_url":"https://api.github.com/repos/janxious/timberline/statuses/{sha}","languages_url":"https://api.github.com/repos/janxious/timberline/languages","stargazers_url":"https://api.github.com/repos/janxious/timberline/stargazers","contributors_url":"https://api.github.com/repos/janxious/timberline/contributors","subscribers_url":"https://api.github.com/repos/janxious/timberline/subscribers","subscription_url":"https://api.github.com/repos/janxious/timberline/subscription","commits_url":"https://api.github.com/repos/janxious/timberline/commits{/sha}","git_commits_url":"https://api.github.com/repos/janxious/timberline/git/commits{/sha}","comments_url":"https://api.github.com/repos/janxious/timberline/comments{/number}","issue_comment_url":"https://api.github.com/repos/janxious/timberline/issues/comments{/number}","contents_url":"https://api.github.com/repos/janxious/timberline/contents/{+path}","compare_url":"https://api.github.com/repos/janxious/timberline/compare/{base}...{head}","merges_url":"https://api.github.com/repos/janxious/timberline/merges","archive_url":"https://api.github.com/repos/janxious/timberline/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/janxious/timberline/downloads","issues_url":"https://api.github.com/repos/janxious/timberline/issues{/number}","pulls_url":"https://api.github.com/repos/janxious/timberline/pulls{/number}","milestones_url":"https://api.github.com/repos/janxious/timberline/milestones{/number}","notifications_url":"https://api.github.com/repos/janxious/timberline/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/janxious/timberline/labels{/name}","releases_url":"https://api.github.com/repos/janxious/timberline/releases{/id}","deployments_url":"https://api.github.com/repos/janxious/timberline/deployments","created_at":"2016-02-25T00:37:20Z","updated_at":"2016-02-25T00:37:20Z","pushed_at":"2016-02-25T02:02:57Z","git_url":"git://github.com/janxious/timberline.git","ssh_url":"git@github.com:janxious/timberline.git","clone_url":"https://github.com/janxious/timberline.git","svn_url":"https://github.com/janxious/timberline","homepage":"","size":124,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"treehouse:master","ref":"master","sha":"8ffdfb222205cf71e561f3ed3ef435b2c1eeda90","user":{"login":"treehouse","id":67474,"avatar_url":"https://avatars.githubusercontent.com/u/67474?v=3","gravatar_id":"","url":"https://api.github.com/users/treehouse","html_url":"https://github.com/treehouse","followers_url":"https://api.github.com/users/treehouse/followers","following_url":"https://api.github.com/users/treehouse/following{/other_user}","gists_url":"https://api.github.com/users/treehouse/gists{/gist_id}","starred_url":"https://api.github.com/users/treehouse/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/treehouse/subscriptions","organizations_url":"https://api.github.com/users/treehouse/orgs","repos_url":"https://api.github.com/users/treehouse/repos","events_url":"https://api.github.com/users/treehouse/events{/privacy}","received_events_url":"https://api.github.com/users/treehouse/received_events","type":"Organization","site_admin":false},"repo":{"id":3371145,"name":"timberline","full_name":"treehouse/timberline","owner":{"login":"treehouse","id":67474,"avatar_url":"https://avatars.githubusercontent.com/u/67474?v=3","gravatar_id":"","url":"https://api.github.com/users/treehouse","html_url":"https://github.com/treehouse","followers_url":"https://api.github.com/users/treehouse/followers","following_url":"https://api.github.com/users/treehouse/following{/other_user}","gists_url":"https://api.github.com/users/treehouse/gists{/gist_id}","starred_url":"https://api.github.com/users/treehouse/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/treehouse/subscriptions","organizations_url":"https://api.github.com/users/treehouse/orgs","repos_url":"https://api.github.com/users/treehouse/repos","events_url":"https://api.github.com/users/treehouse/events{/privacy}","received_events_url":"https://api.github.com/users/treehouse/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/treehouse/timberline","description":"Simple, extensible queuing in Ruby with Redis.","fork":false,"url":"https://api.github.com/repos/treehouse/timberline","forks_url":"https://api.github.com/repos/treehouse/timberline/forks","keys_url":"https://api.github.com/repos/treehouse/timberline/keys{/key_id}","collaborators_url":"https://api.github.com/repos/treehouse/timberline/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/treehouse/timberline/teams","hooks_url":"https://api.github.com/repos/treehouse/timberline/hooks","issue_events_url":"https://api.github.com/repos/treehouse/timberline/issues/events{/number}","events_url":"https://api.github.com/repos/treehouse/timberline/events","assignees_url":"https://api.github.com/repos/treehouse/timberline/assignees{/user}","branches_url":"https://api.github.com/repos/treehouse/timberline/branches{/branch}","tags_url":"https://api.github.com/repos/treehouse/timberline/tags","blobs_url":"https://api.github.com/repos/treehouse/timberline/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/treehouse/timberline/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/treehouse/timberline/git/refs{/sha}","trees_url":"https://api.github.com/repos/treehouse/timberline/git/trees{/sha}","statuses_url":"https://api.github.com/repos/treehouse/timberline/statuses/{sha}","languages_url":"https://api.github.com/repos/treehouse/timberline/languages","stargazers_url":"https://api.github.com/repos/treehouse/timberline/stargazers","contributors_url":"https://api.github.com/repos/treehouse/timberline/contributors","subscribers_url":"https://api.github.com/repos/treehouse/timberline/subscribers","subscription_url":"https://api.github.com/repos/treehouse/timberline/subscription","commits_url":"https://api.github.com/repos/treehouse/timberline/commits{/sha}","git_commits_url":"https://api.github.com/repos/treehouse/timberline/git/commits{/sha}","comments_url":"https://api.github.com/repos/treehouse/timberline/comments{/number}","issue_comment_url":"https://api.github.com/repos/treehouse/timberline/issues/comments{/number}","contents_url":"https://api.github.com/repos/treehouse/timberline/contents/{+path}","compare_url":"https://api.github.com/repos/treehouse/timberline/compare/{base}...{head}","merges_url":"https://api.github.com/repos/treehouse/timberline/merges","archive_url":"https://api.github.com/repos/treehouse/timberline/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/treehouse/timberline/downloads","issues_url":"https://api.github.com/repos/treehouse/timberline/issues{/number}","pulls_url":"https://api.github.com/repos/treehouse/timberline/pulls{/number}","milestones_url":"https://api.github.com/repos/treehouse/timberline/milestones{/number}","notifications_url":"https://api.github.com/repos/treehouse/timberline/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/treehouse/timberline/labels{/name}","releases_url":"https://api.github.com/repos/treehouse/timberline/releases{/id}","deployments_url":"https://api.github.com/repos/treehouse/timberline/deployments","created_at":"2012-02-06T21:19:19Z","updated_at":"2014-12-10T14:22:19Z","pushed_at":"2016-02-25T02:07:36Z","git_url":"git://github.com/treehouse/timberline.git","ssh_url":"git@github.com:treehouse/timberline.git","clone_url":"https://github.com/treehouse/timberline.git","svn_url":"https://github.com/treehouse/timberline","homepage":"","size":130,"stargazers_count":6,"watchers_count":6,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":5,"forks":3,"open_issues":5,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/treehouse/timberline/pulls/15"},"html":{"href":"https://github.com/treehouse/timberline/pull/15"},"issue":{"href":"https://api.github.com/repos/treehouse/timberline/issues/15"},"comments":{"href":"https://api.github.com/repos/treehouse/timberline/issues/15/comments"},"review_comments":{"href":"https://api.github.com/repos/treehouse/timberline/pulls/15/comments"},"review_comment":{"href":"https://api.github.com/repos/treehouse/timberline/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/treehouse/timberline/pulls/15/commits"},"statuses":{"href":"https://api.github.com/repos/treehouse/timberline/statuses/e9021f23e53276ca6bb3bbbcff5064935df66eb1"}}}}