{"action":"created","issue":{"url":"https://api.github.com/repos/azavea/nyc-trees/issues/913","labels_url":"https://api.github.com/repos/azavea/nyc-trees/issues/913/labels{/name}","comments_url":"https://api.github.com/repos/azavea/nyc-trees/issues/913/comments","events_url":"https://api.github.com/repos/azavea/nyc-trees/issues/913/events","html_url":"https://github.com/azavea/nyc-trees/pull/913","id":63027554,"number":913,"title":"Add a management command for starting a scheduled Celery task","user":{"login":"maurizi","id":4432106,"avatar_url":"https://avatars.githubusercontent.com/u/4432106?v=3","gravatar_id":"","url":"https://api.github.com/users/maurizi","html_url":"https://github.com/maurizi","followers_url":"https://api.github.com/users/maurizi/followers","following_url":"https://api.github.com/users/maurizi/following{/other_user}","gists_url":"https://api.github.com/users/maurizi/gists{/gist_id}","starred_url":"https://api.github.com/users/maurizi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maurizi/subscriptions","organizations_url":"https://api.github.com/users/maurizi/orgs","repos_url":"https://api.github.com/users/maurizi/repos","events_url":"https://api.github.com/users/maurizi/events{/privacy}","received_events_url":"https://api.github.com/users/maurizi/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/azavea/nyc-trees/labels/in%20review","name":"in review","color":"ededed"}],"state":"open","locked":false,"assignee":{"login":"maurizi","id":4432106,"avatar_url":"https://avatars.githubusercontent.com/u/4432106?v=3","gravatar_id":"","url":"https://api.github.com/users/maurizi","html_url":"https://github.com/maurizi","followers_url":"https://api.github.com/users/maurizi/followers","following_url":"https://api.github.com/users/maurizi/following{/other_user}","gists_url":"https://api.github.com/users/maurizi/gists{/gist_id}","starred_url":"https://api.github.com/users/maurizi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maurizi/subscriptions","organizations_url":"https://api.github.com/users/maurizi/orgs","repos_url":"https://api.github.com/users/maurizi/repos","events_url":"https://api.github.com/users/maurizi/events{/privacy}","received_events_url":"https://api.github.com/users/maurizi/received_events","type":"User","site_admin":false},"milestone":null,"comments":2,"created_at":"2015-03-19T16:16:21Z","updated_at":"2015-03-19T18:03:55Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/azavea/nyc-trees/pulls/913","html_url":"https://github.com/azavea/nyc-trees/pull/913","diff_url":"https://github.com/azavea/nyc-trees/pull/913.diff","patch_url":"https://github.com/azavea/nyc-trees/pull/913.patch"},"body":"Uses DB locking via `select_for_update` to ensure that the task is only\r\nstarted once per day.\r\n\r\nTo test, run migrations, and then run the following command at the same\r\ntime in two separate shells:\r\n  'manage.py start_daily_celery_task debug_task'\r\n\r\nThe task should only be triggered once, which can be verified by looking\r\nin the Celery logs."},"comment":{"url":"https://api.github.com/repos/azavea/nyc-trees/issues/comments/83695900","html_url":"https://github.com/azavea/nyc-trees/pull/913#issuecomment-83695900","issue_url":"https://api.github.com/repos/azavea/nyc-trees/issues/913","id":83695900,"user":{"login":"steventlamb","id":1699455,"avatar_url":"https://avatars.githubusercontent.com/u/1699455?v=3","gravatar_id":"","url":"https://api.github.com/users/steventlamb","html_url":"https://github.com/steventlamb","followers_url":"https://api.github.com/users/steventlamb/followers","following_url":"https://api.github.com/users/steventlamb/following{/other_user}","gists_url":"https://api.github.com/users/steventlamb/gists{/gist_id}","starred_url":"https://api.github.com/users/steventlamb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/steventlamb/subscriptions","organizations_url":"https://api.github.com/users/steventlamb/orgs","repos_url":"https://api.github.com/users/steventlamb/repos","events_url":"https://api.github.com/users/steventlamb/events{/privacy}","received_events_url":"https://api.github.com/users/steventlamb/received_events","type":"User","site_admin":false},"created_at":"2015-03-19T18:03:55Z","updated_at":"2015-03-19T18:03:55Z","body":"This is limited to day-length locks in a few places to the extent that that's not likely to change. Consider renaming `TaskRun` to `DailyTaskRun`."}}