Revision d9982f38
ID | d9982f3818a4730d4b4d0b728eb110f5f66b34bb |
Parent | 6155a05d |
Child | 5fcaa75b |
(2.13) kvm: Delegate socket handling to monitor module
Introduce @_ensure_connection decorator that properly handles
the socket connection (i.e. connect, close) and propagates
any exceptions raised in the decorated method.
In general @_ensure_connection wraps external methods.
Here we close the connection only if we initiated it before,
to protect us from using the socket after closing it
in case we invoke a decorated method internally by accident.
Rename all private methods of QmpConnection properly.
Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
Reviewed-by: Hrvoje Ribicic <riba@google.com>
Files
- added
- modified
- copied
- renamed
- deleted