{"action":"created","issue":{"url":"https://api.github.com/repos/hashicorp/nomad/issues/1079","repository_url":"https://api.github.com/repos/hashicorp/nomad","labels_url":"https://api.github.com/repos/hashicorp/nomad/issues/1079/labels{/name}","comments_url":"https://api.github.com/repos/hashicorp/nomad/issues/1079/comments","events_url":"https://api.github.com/repos/hashicorp/nomad/issues/1079/events","html_url":"https://github.com/hashicorp/nomad/issues/1079","id":147833446,"number":1079,"title":"Configure cleanup behavior","user":{"login":"sheerun","id":292365,"avatar_url":"https://avatars.githubusercontent.com/u/292365?v=3","gravatar_id":"","url":"https://api.github.com/users/sheerun","html_url":"https://github.com/sheerun","followers_url":"https://api.github.com/users/sheerun/followers","following_url":"https://api.github.com/users/sheerun/following{/other_user}","gists_url":"https://api.github.com/users/sheerun/gists{/gist_id}","starred_url":"https://api.github.com/users/sheerun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sheerun/subscriptions","organizations_url":"https://api.github.com/users/sheerun/orgs","repos_url":"https://api.github.com/users/sheerun/repos","events_url":"https://api.github.com/users/sheerun/events{/privacy}","received_events_url":"https://api.github.com/users/sheerun/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-04-12T18:19:23Z","updated_at":"2016-04-14T21:31:37Z","closed_at":null,"body":"The documentation says following about garbage collection behavior:\r\n\r\n> Both these directories are persisted until the allocation is removed, which occurs hours after all the tasks in the task group enter terminal states. This gives time to view the data produced by tasks.\r\n\r\nBut I'd like to be able to configure this period, or actually to prevent gc at all until I explicitly remove allocation. I suggest to introdue per-task option to configure this period and to implement DELETE method for allocations."},"comment":{"url":"https://api.github.com/repos/hashicorp/nomad/issues/comments/210156867","html_url":"https://github.com/hashicorp/nomad/issues/1079#issuecomment-210156867","issue_url":"https://api.github.com/repos/hashicorp/nomad/issues/1079","id":210156867,"user":{"login":"diptanu","id":21833,"avatar_url":"https://avatars.githubusercontent.com/u/21833?v=3","gravatar_id":"","url":"https://api.github.com/users/diptanu","html_url":"https://github.com/diptanu","followers_url":"https://api.github.com/users/diptanu/followers","following_url":"https://api.github.com/users/diptanu/following{/other_user}","gists_url":"https://api.github.com/users/diptanu/gists{/gist_id}","starred_url":"https://api.github.com/users/diptanu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/diptanu/subscriptions","organizations_url":"https://api.github.com/users/diptanu/orgs","repos_url":"https://api.github.com/users/diptanu/repos","events_url":"https://api.github.com/users/diptanu/events{/privacy}","received_events_url":"https://api.github.com/users/diptanu/received_events","type":"User","site_admin":false},"created_at":"2016-04-14T21:31:37Z","updated_at":"2016-04-14T21:31:37Z","body":"@sheerun So there are some issues around this.\r\n\r\na. Allowing configuration of per task GC of a Task - This would allow end-users to control internal behavior of Nomad and it will be hard to reason for operators or auditing systems to get any forensic data deterministically out of an allocation which ran on a client node.\r\n\r\nb. Leaving allocation directories around until a user has intervened and asked Nomad to explicitly GC the allocation means that we will not be freeing up disk resources when a job finishes. This works fine if the size of clusters are small but breaks down the cluster size is 10s of 1000s of machines since at that scale very little manual intervention is desired. If operators or users want to see information from allocation directories beyond what Nomad client is going to have, pushing the contents to a centralized blob storage or logging service works well."}}