{"action":"created","issue":{"url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/issues/195","repository_url":"https://api.github.com/repos/zhmcclient/python-zhmcclient","labels_url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/issues/195/labels{/name}","comments_url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/issues/195/comments","events_url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/issues/195/events","html_url":"https://github.com/zhmcclient/python-zhmcclient/pull/195","id":205742357,"number":195,"title":"[WIP] Fixes #6, Fixes #191: Timeout support for async methods; deferred status polling for LPAR","user":{"login":"andy-maier","id":8939758,"avatar_url":"https://avatars1.githubusercontent.com/u/8939758?v=3","gravatar_id":"","url":"https://api.github.com/users/andy-maier","html_url":"https://github.com/andy-maier","followers_url":"https://api.github.com/users/andy-maier/followers","following_url":"https://api.github.com/users/andy-maier/following{/other_user}","gists_url":"https://api.github.com/users/andy-maier/gists{/gist_id}","starred_url":"https://api.github.com/users/andy-maier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andy-maier/subscriptions","organizations_url":"https://api.github.com/users/andy-maier/orgs","repos_url":"https://api.github.com/users/andy-maier/repos","events_url":"https://api.github.com/users/andy-maier/events{/privacy}","received_events_url":"https://api.github.com/users/andy-maier/received_events","type":"User","site_admin":false},"labels":[{"id":439501531,"url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/labels/discussion%20needed","name":"discussion needed","color":"159818","default":false}],"state":"open","locked":false,"assignee":{"login":"andy-maier","id":8939758,"avatar_url":"https://avatars1.githubusercontent.com/u/8939758?v=3","gravatar_id":"","url":"https://api.github.com/users/andy-maier","html_url":"https://github.com/andy-maier","followers_url":"https://api.github.com/users/andy-maier/followers","following_url":"https://api.github.com/users/andy-maier/following{/other_user}","gists_url":"https://api.github.com/users/andy-maier/gists{/gist_id}","starred_url":"https://api.github.com/users/andy-maier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andy-maier/subscriptions","organizations_url":"https://api.github.com/users/andy-maier/orgs","repos_url":"https://api.github.com/users/andy-maier/repos","events_url":"https://api.github.com/users/andy-maier/events{/privacy}","received_events_url":"https://api.github.com/users/andy-maier/received_events","type":"User","site_admin":false},"assignees":[{"login":"andy-maier","id":8939758,"avatar_url":"https://avatars1.githubusercontent.com/u/8939758?v=3","gravatar_id":"","url":"https://api.github.com/users/andy-maier","html_url":"https://github.com/andy-maier","followers_url":"https://api.github.com/users/andy-maier/followers","following_url":"https://api.github.com/users/andy-maier/following{/other_user}","gists_url":"https://api.github.com/users/andy-maier/gists{/gist_id}","starred_url":"https://api.github.com/users/andy-maier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andy-maier/subscriptions","organizations_url":"https://api.github.com/users/andy-maier/orgs","repos_url":"https://api.github.com/users/andy-maier/repos","events_url":"https://api.github.com/users/andy-maier/events{/privacy}","received_events_url":"https://api.github.com/users/andy-maier/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/milestones/11","html_url":"https://github.com/zhmcclient/python-zhmcclient/milestone/11","labels_url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/milestones/11/labels","id":2295648,"number":11,"title":"0.11.0","description":"","creator":{"login":"leopoldjuergen","id":19662677,"avatar_url":"https://avatars3.githubusercontent.com/u/19662677?v=3","gravatar_id":"","url":"https://api.github.com/users/leopoldjuergen","html_url":"https://github.com/leopoldjuergen","followers_url":"https://api.github.com/users/leopoldjuergen/followers","following_url":"https://api.github.com/users/leopoldjuergen/following{/other_user}","gists_url":"https://api.github.com/users/leopoldjuergen/gists{/gist_id}","starred_url":"https://api.github.com/users/leopoldjuergen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leopoldjuergen/subscriptions","organizations_url":"https://api.github.com/users/leopoldjuergen/orgs","repos_url":"https://api.github.com/users/leopoldjuergen/repos","events_url":"https://api.github.com/users/leopoldjuergen/events{/privacy}","received_events_url":"https://api.github.com/users/leopoldjuergen/received_events","type":"User","site_admin":false},"open_issues":11,"closed_issues":22,"state":"open","created_at":"2017-02-02T17:19:32Z","updated_at":"2017-03-08T23:32:09Z","due_on":"2017-02-16T08:00:00Z","closed_at":null},"comments":4,"created_at":"2017-02-06T23:45:20Z","updated_at":"2017-03-08T23:49:44Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/pulls/195","html_url":"https://github.com/zhmcclient/python-zhmcclient/pull/195","diff_url":"https://github.com/zhmcclient/python-zhmcclient/pull/195.diff","patch_url":"https://github.com/zhmcclient/python-zhmcclient/pull/195.patch"},"body":"Please review and merge.\r\n\r\nPlease focus on the changes at the API, more than on the implementation code.\r\n\r\nGood questions would be, for example:\r\n\r\n- The new `TimeoutError` class is used for both async operation timeouts and status polling timeouts, and it does not have a machine-readable way to distinguish these cases. This affects only the `Lpar.activate/dectivate/load()` methods. Is this good enough?\r\n- Are the default timeouts right (see the new `_constants.py` module)?\r\n- The use of `Lpar.activate/dectivate/load()` with `wait_for_completion=False` returns a Job object that can handle the waiting for job completion, but not the waiting for deferred status update. On the one hand, this may be what you expect from an asynchronous job, on the other hand, it is not consistent with the `wait_for_completion=True` case, where both is done by the zhmcclient library.\r\n\r\nDetails, from the commit message:\r\n\r\n- Added exception class `TimeoutError` that is used to indicate operation timeout and status polling timeout.\r\n- Added support for deferred status polling to the `Lpar.activate/deactivate/load()` methods.i\r\n  Background: The HMC operations issued by these methods exhibit show deferred status ibehavior, which means that it takes a few seconds after successful completion of the async job that executes the operation, until the new status can be observed in the 'status' property of the LPAR resource.\r\n  These methods will poll the LPAR status until the desired status value is reached. A status timeout can be specified via a new `status_timeout` parameter to these methods, which defaults to 1h. The long timeout duration means this is just a last resort.\r\n- Added operation timeout support to `Session.post()` and to all resource methods with a `wait_for_completion` parameter (i.e. the asynchronous methods). The operation timeout on the async methods can be specified via a new `operation_timeout` parameter, which defaults to no timeout.\r\n- Added a new module `_constants` to define the default timeout values for the operation timeout and the status timeout."},"comment":{"url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/issues/comments/285208325","html_url":"https://github.com/zhmcclient/python-zhmcclient/pull/195#issuecomment-285208325","issue_url":"https://api.github.com/repos/zhmcclient/python-zhmcclient/issues/195","id":285208325,"user":{"login":"coveralls","id":2354108,"avatar_url":"https://avatars2.githubusercontent.com/u/2354108?v=3","gravatar_id":"","url":"https://api.github.com/users/coveralls","html_url":"https://github.com/coveralls","followers_url":"https://api.github.com/users/coveralls/followers","following_url":"https://api.github.com/users/coveralls/following{/other_user}","gists_url":"https://api.github.com/users/coveralls/gists{/gist_id}","starred_url":"https://api.github.com/users/coveralls/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coveralls/subscriptions","organizations_url":"https://api.github.com/users/coveralls/orgs","repos_url":"https://api.github.com/users/coveralls/repos","events_url":"https://api.github.com/users/coveralls/events{/privacy}","received_events_url":"https://api.github.com/users/coveralls/received_events","type":"User","site_admin":false},"created_at":"2017-03-08T23:49:44Z","updated_at":"2017-03-08T23:49:44Z","body":"\n[![Coverage Status](https://coveralls.io/builds/10501086/badge)](https://coveralls.io/builds/10501086)\n\nCoverage decreased (-0.2%) to 88.956% when pulling **9de0b5c5babee3befa80d5b367ff5ec0b8d72fa9 on andy/deferred-status** into **d487635ccdc8b4947e661ff4773d5c2a7de79f0c on master**.\n"}}
{"actor":{"display_login":"coveralls"}}