{"action":"created","issue":{"url":"https://api.github.com/repos/influxdata/kapacitor/issues/285","repository_url":"https://api.github.com/repos/influxdata/kapacitor","labels_url":"https://api.github.com/repos/influxdata/kapacitor/issues/285/labels{/name}","comments_url":"https://api.github.com/repos/influxdata/kapacitor/issues/285/comments","events_url":"https://api.github.com/repos/influxdata/kapacitor/issues/285/events","html_url":"https://github.com/influxdata/kapacitor/issues/285","id":138525164,"number":285,"title":"Garbage collecting tasks","user":{"login":"lpalm","id":8668240,"avatar_url":"https://avatars.githubusercontent.com/u/8668240?v=3","gravatar_id":"","url":"https://api.github.com/users/lpalm","html_url":"https://github.com/lpalm","followers_url":"https://api.github.com/users/lpalm/followers","following_url":"https://api.github.com/users/lpalm/following{/other_user}","gists_url":"https://api.github.com/users/lpalm/gists{/gist_id}","starred_url":"https://api.github.com/users/lpalm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lpalm/subscriptions","organizations_url":"https://api.github.com/users/lpalm/orgs","repos_url":"https://api.github.com/users/lpalm/repos","events_url":"https://api.github.com/users/lpalm/events{/privacy}","received_events_url":"https://api.github.com/users/lpalm/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-03-04T16:56:57Z","updated_at":"2016-03-04T17:11:56Z","closed_at":null,"body":"I have test tasks that users iterate on by backtesting them until they reach a desired configuration and threshold. Once that happens, the task is upgraded to a production task which can be managed manually.\r\nNot all backtested tasks will graduate to production, and some may be abandoned for a while and be worked on again. These build up so we'd like to be able to periodically and automatically clean up any tasks that haven't been run in the last X weeks. Currently I don't see a way to get the last modified time or last active time of a task. Is this available somewhere? These tasks backtest tasks would only ever be used to record and replay past data.\r\nI could potentially add a \"created\" timestamp to the name of the task, but this feels a bit kludgy and might cause problems for tasks that are being actively worked on.\r\n"},"comment":{"url":"https://api.github.com/repos/influxdata/kapacitor/issues/comments/192362388","html_url":"https://github.com/influxdata/kapacitor/issues/285#issuecomment-192362388","issue_url":"https://api.github.com/repos/influxdata/kapacitor/issues/285","id":192362388,"user":{"login":"nathanielc","id":3771906,"avatar_url":"https://avatars.githubusercontent.com/u/3771906?v=3","gravatar_id":"","url":"https://api.github.com/users/nathanielc","html_url":"https://github.com/nathanielc","followers_url":"https://api.github.com/users/nathanielc/followers","following_url":"https://api.github.com/users/nathanielc/following{/other_user}","gists_url":"https://api.github.com/users/nathanielc/gists{/gist_id}","starred_url":"https://api.github.com/users/nathanielc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nathanielc/subscriptions","organizations_url":"https://api.github.com/users/nathanielc/orgs","repos_url":"https://api.github.com/users/nathanielc/repos","events_url":"https://api.github.com/users/nathanielc/events{/privacy}","received_events_url":"https://api.github.com/users/nathanielc/received_events","type":"User","site_admin":false},"created_at":"2016-03-04T17:11:56Z","updated_at":"2016-03-04T17:11:56Z","body":"Those stats are not available but can be added: Would adding a created and last enabled date be enough, to implement the clean up code on your end?\r\n"}}