{"action":"created","issue":{"url":"https://api.github.com/repos/owncloud/core/issues/20425","labels_url":"https://api.github.com/repos/owncloud/core/issues/20425/labels{/name}","comments_url":"https://api.github.com/repos/owncloud/core/issues/20425/comments","events_url":"https://api.github.com/repos/owncloud/core/issues/20425/events","html_url":"https://github.com/owncloud/core/issues/20425","id":116071550,"number":20425,"title":"Jobs table is pilling up a lot of \"OC\\Command\\CommandJob\" jobs","user":{"login":"MorrisJobke","id":245432,"avatar_url":"https://avatars.githubusercontent.com/u/245432?v=3","gravatar_id":"","url":"https://api.github.com/users/MorrisJobke","html_url":"https://github.com/MorrisJobke","followers_url":"https://api.github.com/users/MorrisJobke/followers","following_url":"https://api.github.com/users/MorrisJobke/following{/other_user}","gists_url":"https://api.github.com/users/MorrisJobke/gists{/gist_id}","starred_url":"https://api.github.com/users/MorrisJobke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MorrisJobke/subscriptions","organizations_url":"https://api.github.com/users/MorrisJobke/orgs","repos_url":"https://api.github.com/users/MorrisJobke/repos","events_url":"https://api.github.com/users/MorrisJobke/events{/privacy}","received_events_url":"https://api.github.com/users/MorrisJobke/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/owncloud/core/labels/8.1.5-current","name":"8.1.5-current","color":"996633"},{"url":"https://api.github.com/repos/owncloud/core/labels/8.2.2-current","name":"8.2.2-current","color":"996633"},{"url":"https://api.github.com/repos/owncloud/core/labels/app:files_trashbin","name":"app:files_trashbin","color":"02d7e1"},{"url":"https://api.github.com/repos/owncloud/core/labels/bug","name":"bug","color":"fc2929"},{"url":"https://api.github.com/repos/owncloud/core/labels/resolves-blue-ticket","name":"resolves-blue-ticket","color":"0033CC"},{"url":"https://api.github.com/repos/owncloud/core/labels/sev2-high","name":"sev2-high","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/owncloud/core/milestones/48","html_url":"https://github.com/owncloud/core/milestones/9.0-current","labels_url":"https://api.github.com/repos/owncloud/core/milestones/48/labels","id":1196845,"number":48,"title":"9.0-current","description":"","creator":{"login":"cmonteroluque","id":879976,"avatar_url":"https://avatars.githubusercontent.com/u/879976?v=3","gravatar_id":"","url":"https://api.github.com/users/cmonteroluque","html_url":"https://github.com/cmonteroluque","followers_url":"https://api.github.com/users/cmonteroluque/followers","following_url":"https://api.github.com/users/cmonteroluque/following{/other_user}","gists_url":"https://api.github.com/users/cmonteroluque/gists{/gist_id}","starred_url":"https://api.github.com/users/cmonteroluque/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cmonteroluque/subscriptions","organizations_url":"https://api.github.com/users/cmonteroluque/orgs","repos_url":"https://api.github.com/users/cmonteroluque/repos","events_url":"https://api.github.com/users/cmonteroluque/events{/privacy}","received_events_url":"https://api.github.com/users/cmonteroluque/received_events","type":"User","site_admin":false},"open_issues":601,"closed_issues":664,"state":"open","created_at":"2015-07-07T14:21:23Z","updated_at":"2015-12-10T10:02:28Z","due_on":"2016-03-08T04:00:00Z","closed_at":null},"comments":45,"created_at":"2015-11-10T09:44:23Z","updated_at":"2015-12-10T10:04:33Z","closed_at":"2015-11-27T15:04:03Z","body":"```\r\nSELECT class, COUNT(*) FROM oc_jobs GROUP BY class;\r\n+-----------------------------------------------+----------+\r\n| class                                         | COUNT(*) |\r\n+-----------------------------------------------+----------+\r\n| OCA\\Activity\\BackgroundJob\\EmailNotification  |        2 |\r\n| OCA\\Activity\\BackgroundJob\\ExpireActivities   |        5 |\r\n| OCA\\Files_sharing\\Lib\\DeleteOrphanedSharesJob |        1 |\r\n| OCA\\user_ldap\\lib\\Jobs                        |        1 |\r\n| OC\\Command\\CommandJob                         |  2198563 |\r\n| \\OCA\\User_LDAP\\Jobs\\CleanUp                   |        1 |\r\n+-----------------------------------------------+----------+\r\n6 rows in set (0.47 sec)\r\n```\r\n\r\nNow the cron job is running endless.\r\n\r\nThose command jobs are mostly trash bin and version expiries. I guess we need a way to parallelize those CommandJobs and trigger them separately. Otherwise big instances will have a huge problem of endless running cron.php calls and the actual cron behavior is killed.\r\n\r\nThis is on a 8.1.3 instance.\r\n\r\n@cmonteroluque @karlitschek I rated this as a sev2-high ticket and put it in the current milestone. (feel free to change this)\r\n\r\n@icewind1991 @PVince81 @nickvergessen @schiesbn I would really like to have your opinion on this. I think the CommandJobs can easily parallelized, because they are independent (or should be)."},"comment":{"url":"https://api.github.com/repos/owncloud/core/issues/comments/163562689","html_url":"https://github.com/owncloud/core/issues/20425#issuecomment-163562689","issue_url":"https://api.github.com/repos/owncloud/core/issues/20425","id":163562689,"user":{"login":"MorrisJobke","id":245432,"avatar_url":"https://avatars.githubusercontent.com/u/245432?v=3","gravatar_id":"","url":"https://api.github.com/users/MorrisJobke","html_url":"https://github.com/MorrisJobke","followers_url":"https://api.github.com/users/MorrisJobke/followers","following_url":"https://api.github.com/users/MorrisJobke/following{/other_user}","gists_url":"https://api.github.com/users/MorrisJobke/gists{/gist_id}","starred_url":"https://api.github.com/users/MorrisJobke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MorrisJobke/subscriptions","organizations_url":"https://api.github.com/users/MorrisJobke/orgs","repos_url":"https://api.github.com/users/MorrisJobke/repos","events_url":"https://api.github.com/users/MorrisJobke/events{/privacy}","received_events_url":"https://api.github.com/users/MorrisJobke/received_events","type":"User","site_admin":false},"created_at":"2015-12-10T10:04:33Z","updated_at":"2015-12-10T10:04:33Z","body":"I just received an update on this: The trashbin is not the only problem: version expire has a similar problem: https://github.com/owncloud/core/issues/21108"}}