{"action":"created","issue":{"url":"https://api.github.com/repos/fog/fog/issues/3726","labels_url":"https://api.github.com/repos/fog/fog/issues/3726/labels{/name}","comments_url":"https://api.github.com/repos/fog/fog/issues/3726/comments","events_url":"https://api.github.com/repos/fog/fog/issues/3726/events","html_url":"https://github.com/fog/fog/issues/3726","id":112405931,"number":3726,"title":"[openstack] inconsistent model-collection methods to get by id","user":{"login":"dhague","id":562527,"avatar_url":"https://avatars.githubusercontent.com/u/562527?v=3","gravatar_id":"","url":"https://api.github.com/users/dhague","html_url":"https://github.com/dhague","followers_url":"https://api.github.com/users/dhague/followers","following_url":"https://api.github.com/users/dhague/following{/other_user}","gists_url":"https://api.github.com/users/dhague/gists{/gist_id}","starred_url":"https://api.github.com/users/dhague/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dhague/subscriptions","organizations_url":"https://api.github.com/users/dhague/orgs","repos_url":"https://api.github.com/users/dhague/repos","events_url":"https://api.github.com/users/dhague/events{/privacy}","received_events_url":"https://api.github.com/users/dhague/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-10-20T16:18:20Z","updated_at":"2015-10-21T08:24:33Z","closed_at":null,"body":"In Fog, the model collections classes (typically the pluralised names in lib/fog/*provider*/models/*service*) have a get(id) method to fetch a model object by its ID.\r\nIn the case where the ID cannot be found, the get(id) method typically swallows the NotFound exception and returns nil.\r\n\r\nIn the OpenStack provider case, some classes use get(id) as described above, some use get(id) but do not swallow the NotFound exception, some classes use find_by_id(id) and not not swallow the exception, and in one case both methods are supported with find_by_id being marked as deprecated. \r\n\r\nIn other words, there is a great deal of inconsistency in how to get a model object by its ID in the Fog OpenStack provider."},"comment":{"url":"https://api.github.com/repos/fog/fog/issues/comments/149814540","html_url":"https://github.com/fog/fog/issues/3726#issuecomment-149814540","issue_url":"https://api.github.com/repos/fog/fog/issues/3726","id":149814540,"user":{"login":"dhague","id":562527,"avatar_url":"https://avatars.githubusercontent.com/u/562527?v=3","gravatar_id":"","url":"https://api.github.com/users/dhague","html_url":"https://github.com/dhague","followers_url":"https://api.github.com/users/dhague/followers","following_url":"https://api.github.com/users/dhague/following{/other_user}","gists_url":"https://api.github.com/users/dhague/gists{/gist_id}","starred_url":"https://api.github.com/users/dhague/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dhague/subscriptions","organizations_url":"https://api.github.com/users/dhague/orgs","repos_url":"https://api.github.com/users/dhague/repos","events_url":"https://api.github.com/users/dhague/events{/privacy}","received_events_url":"https://api.github.com/users/dhague/received_events","type":"User","site_admin":false},"created_at":"2015-10-21T08:24:33Z","updated_at":"2015-10-21T08:24:33Z","body":"@Ladas sounds like a good plan - I'll get to work on it."}}