{"action":"created","issue":{"url":"https://api.github.com/repos/theforeman/foreman/issues/4996","repository_url":"https://api.github.com/repos/theforeman/foreman","labels_url":"https://api.github.com/repos/theforeman/foreman/issues/4996/labels{/name}","comments_url":"https://api.github.com/repos/theforeman/foreman/issues/4996/comments","events_url":"https://api.github.com/repos/theforeman/foreman/issues/4996/events","html_url":"https://github.com/theforeman/foreman/pull/4996","id":272623542,"number":4996,"title":"Fixes #21599 - Improved fact importing mechanism to deal with names","user":{"login":"ShimShtein","id":10046168,"avatar_url":"https://avatars0.githubusercontent.com/u/10046168?v=4","gravatar_id":"","url":"https://api.github.com/users/ShimShtein","html_url":"https://github.com/ShimShtein","followers_url":"https://api.github.com/users/ShimShtein/followers","following_url":"https://api.github.com/users/ShimShtein/following{/other_user}","gists_url":"https://api.github.com/users/ShimShtein/gists{/gist_id}","starred_url":"https://api.github.com/users/ShimShtein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ShimShtein/subscriptions","organizations_url":"https://api.github.com/users/ShimShtein/orgs","repos_url":"https://api.github.com/users/ShimShtein/repos","events_url":"https://api.github.com/users/ShimShtein/events{/privacy}","received_events_url":"https://api.github.com/users/ShimShtein/received_events","type":"User","site_admin":false},"labels":[{"id":79040160,"url":"https://api.github.com/repos/theforeman/foreman/labels/Needs%20re-review","name":"Needs re-review","color":"0052cc","default":false},{"id":79040689,"url":"https://api.github.com/repos/theforeman/foreman/labels/Needs%20testing","name":"Needs testing","color":"fbca04","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":17,"created_at":"2017-11-09T16:18:50Z","updated_at":"2017-11-20T08:33:41Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/theforeman/foreman/pulls/4996","html_url":"https://github.com/theforeman/foreman/pull/4996","diff_url":"https://github.com/theforeman/foreman/pull/4996.diff","patch_url":"https://github.com/theforeman/foreman/pull/4996.patch"},"body":"Now the list of fact names will be calculated beforehand and saved to the database. It will also consider that the name could be added from other thread."},"comment":{"url":"https://api.github.com/repos/theforeman/foreman/issues/comments/345625126","html_url":"https://github.com/theforeman/foreman/pull/4996#issuecomment-345625126","issue_url":"https://api.github.com/repos/theforeman/foreman/issues/4996","id":345625126,"user":{"login":"ShimShtein","id":10046168,"avatar_url":"https://avatars0.githubusercontent.com/u/10046168?v=4","gravatar_id":"","url":"https://api.github.com/users/ShimShtein","html_url":"https://github.com/ShimShtein","followers_url":"https://api.github.com/users/ShimShtein/followers","following_url":"https://api.github.com/users/ShimShtein/following{/other_user}","gists_url":"https://api.github.com/users/ShimShtein/gists{/gist_id}","starred_url":"https://api.github.com/users/ShimShtein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ShimShtein/subscriptions","organizations_url":"https://api.github.com/users/ShimShtein/orgs","repos_url":"https://api.github.com/users/ShimShtein/repos","events_url":"https://api.github.com/users/ShimShtein/events{/privacy}","received_events_url":"https://api.github.com/users/ShimShtein/received_events","type":"User","site_admin":false},"created_at":"2017-11-20T08:33:41Z","updated_at":"2017-11-20T08:33:41Z","author_association":"MEMBER","body":"@lzap I have improved the memory footprint to something more or less equal to the previous version. Also added the memory benchmark test.\r\n\r\nI was thinking about plucking only the name and id for fact names (instead of retaining the whole `FactName` model), but in structured fact importer we are using ancestry gem that will fetch the record, if we supply `:parent_id => fact_name_id` statement. "}}
{"actor":{"display_login":"ShimShtein"}}