{"action":"created","issue":{"url":"https://api.github.com/repos/ManageIQ/manageiq/issues/3978","labels_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/3978/labels{/name}","comments_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/3978/comments","events_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/3978/events","html_url":"https://github.com/ManageIQ/manageiq/pull/3978","id":102256324,"number":3978,"title":"containers: add kubernetes images scanning","user":{"login":"simon3z","id":130393,"avatar_url":"https://avatars.githubusercontent.com/u/130393?v=3","gravatar_id":"","url":"https://api.github.com/users/simon3z","html_url":"https://github.com/simon3z","followers_url":"https://api.github.com/users/simon3z/followers","following_url":"https://api.github.com/users/simon3z/following{/other_user}","gists_url":"https://api.github.com/users/simon3z/gists{/gist_id}","starred_url":"https://api.github.com/users/simon3z/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simon3z/subscriptions","organizations_url":"https://api.github.com/users/simon3z/orgs","repos_url":"https://api.github.com/users/simon3z/repos","events_url":"https://api.github.com/users/simon3z/events{/privacy}","received_events_url":"https://api.github.com/users/simon3z/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ManageIQ/manageiq/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/ManageIQ/manageiq/labels/fleecing","name":"fleecing","color":"5319e7"},{"url":"https://api.github.com/repos/ManageIQ/manageiq/labels/providers/containers","name":"providers/containers","color":"5319e7"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-08-20T22:53:36Z","updated_at":"2015-09-09T12:36:38Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/3978","html_url":"https://github.com/ManageIQ/manageiq/pull/3978","diff_url":"https://github.com/ManageIQ/manageiq/pull/3978.diff","patch_url":"https://github.com/ManageIQ/manageiq/pull/3978.patch"},"body":""},"comment":{"url":"https://api.github.com/repos/ManageIQ/manageiq/issues/comments/138895906","html_url":"https://github.com/ManageIQ/manageiq/pull/3978#issuecomment-138895906","issue_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/3978","id":138895906,"user":{"login":"simon3z","id":130393,"avatar_url":"https://avatars.githubusercontent.com/u/130393?v=3","gravatar_id":"","url":"https://api.github.com/users/simon3z","html_url":"https://github.com/simon3z","followers_url":"https://api.github.com/users/simon3z/followers","following_url":"https://api.github.com/users/simon3z/following{/other_user}","gists_url":"https://api.github.com/users/simon3z/gists{/gist_id}","starred_url":"https://api.github.com/users/simon3z/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simon3z/subscriptions","organizations_url":"https://api.github.com/users/simon3z/orgs","repos_url":"https://api.github.com/users/simon3z/repos","events_url":"https://api.github.com/users/simon3z/events{/privacy}","received_events_url":"https://api.github.com/users/simon3z/received_events","type":"User","site_admin":false},"created_at":"2015-09-09T12:36:38Z","updated_at":"2015-09-09T12:36:38Z","body":"> @simon3z in what way are scan_metadata and sync_metadata VM-specific?\r\n> I know you're not using the server_smart_proxy (not host/smart_proxy), that's why I asked why you were bypassing it.\r\n\r\n@roliveri `scan_metadata` and `sync_metadata` are VM-specific because they assume you have [a smart proxy `host`](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/mixins/scanning_mixin.rb#L162) on which you'll `queue_call`. Tracing back where `host` comes from, you'll see that it is generated from `agent_class` and `agent_id` [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/vm_scan.rb#L85) and then continuing back you'll hit `job_proxy_dispatcher` setting the `agent_class` and `agent_id` [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L124-L127), [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L115), then following the `proxy` [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L82), [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L67), [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L66) you'll get to `get_eligible_proxies_for_job` [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L275) which requires `proxies4job` [here](https://github.com/ManageIQ/manageiq/blob/2a59f4c/app/models/job_proxy_dispatcher.rb#L298)\r\n\r\nAs you see there are many dependencies on `JobProxyDispatcher` (which is very much VM-oriented) if we use `scan_metadata` and `sync_metadata`.\r\n\r\nThe idea was to avoid `JobProxyDispatcher` since it requires a large refactor at this point and it's not clear if will be maintained in the future. As you said:\r\n\r\n> While no special dispatch is needed for Container SSA, the JobProxyDispatcher is still required to initiate the job.\r\n\r\nActually it is possible to initiate the job also without the `JobProxyDispatcher` (as in this PR).\r\n\r\n> There has also been talk of removing the JobProxyDispatcher completely, so we’ll have to determine the best course to take.\r\n\r\nGiven the uncertain fate of `JobProxyDispatcher` and the fact that there's no need to have a dispatcher for containers, I'd stay away from that part.\r\n\r\n\r\n\r\n"}}