Displaying 5 results from an estimated 5 matches for "_create_unix_socket".
2018 Jun 21
0
[PATCH 2/2] v2v: -o rhv-upload: Use Unix domain socket to access imageio (RHBZ#1588088).
...ot supported")
+
+class UnixHTTPConnection(_UnixMixin, HTTPConnection):
+ def __init__(self, path, timeout=socket._GLOBAL_DEFAULT_TIMEOUT):
+ self.path = path
+ HTTPConnection.__init__(self, "localhost", timeout=timeout)
+
+ def connect(self):
+ self.sock = _create_unix_socket(self.timeout)
+ self.sock.connect(self.path)
+
+def _create_unix_socket(timeout):
+ sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
+ if timeout is not socket._GLOBAL_DEFAULT_TIMEOUT:
+ sock.settimeout(timeout)
+ return sock
--
2.16.2
2018 Jun 22
0
[PATCH v2 2/2] v2v: -o rhv-upload: Use Unix domain socket to access imageio (RHBZ#1588088).
...ot supported")
+
+class UnixHTTPConnection(_UnixMixin, HTTPConnection):
+ def __init__(self, path, timeout=socket._GLOBAL_DEFAULT_TIMEOUT):
+ self.path = path
+ HTTPConnection.__init__(self, "localhost", timeout=timeout)
+
+ def connect(self):
+ self.sock = _create_unix_socket(self.timeout)
+ self.sock.connect(self.path)
+
+def _create_unix_socket(timeout):
+ sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
+ if timeout is not socket._GLOBAL_DEFAULT_TIMEOUT:
+ sock.settimeout(timeout)
+ return sock
--
2.16.2
2018 Jun 22
4
v2v: -o rhv-upload: Use Unix domain socket to access imageio (RHBZ#1588088).
v1 was here:
https://www.redhat.com/archives/libguestfs/2018-June/msg00099.html
v2:
- Just fixes the two problems noted in the review of the previous version.
Rich.
2018 Jun 21
6
v2v: -o rhv-upload: Use Unix domain socket to access imageio (RHBZ#1588088).
These two patches add support for using a Unix domain socket to
directly access imageio in the case where imageio is running on the
conversion host (usually that means virt-v2v is running on the RHV
node and something else -- eg. CFME scripts -- arranges that the RHV
node is the same one running imageio).
Conversions in the normal case are not affected - they happen over TCP
as usual.
This was
2018 Jun 25
1
Re: [PATCH v2 2/2] v2v: -o rhv-upload: Use Unix domain socket to access imageio (RHBZ#1588088).
...nixHTTPConnection(_UnixMixin, HTTPConnection):
> + def __init__(self, path, timeout=socket._GLOBAL_DEFAULT_TIMEOUT):
> + self.path = path
> + HTTPConnection.__init__(self, "localhost", timeout=timeout)
> +
> + def connect(self):
> + self.sock = _create_unix_socket(self.timeout)
> + self.sock.connect(self.path)
> +
> +def _create_unix_socket(timeout):
> + sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
> + if timeout is not socket._GLOBAL_DEFAULT_TIMEOUT:
> + sock.settimeout(timeout)
> + return sock
>
I...