<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/gitlab/gitlab-shell.git/lib/gitlab_net.rb, branch gl_ee_issue_116</title>
<subtitle>gitlab.com: gitlab-org/gitlab-shell.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/'/>
<entry>
<title>Add encoding for the ssh key on the url</title>
<updated>2016-03-24T20:48:27+00:00</updated>
<author>
<name>Pablo Carranza</name>
<email>pcarranza@gmail.com</email>
</author>
<published>2016-03-11T14:37:11+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=79aed51b9010151a48cc519e41d0805e652cb24e'/>
<id>79aed51b9010151a48cc519e41d0805e652cb24e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Change use of fingerprint for whole key</title>
<updated>2016-03-24T20:48:27+00:00</updated>
<author>
<name>Pablo Carranza</name>
<email>pcarranza@gmail.com</email>
</author>
<published>2016-03-11T12:41:18+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=aedf824d2d7f5bce34d9e8dba728af05ea236b79'/>
<id>aedf824d2d7f5bce34d9e8dba728af05ea236b79</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Change API endpoint to authorized_keys</title>
<updated>2016-03-24T20:48:27+00:00</updated>
<author>
<name>Pablo Carranza</name>
<email>pcarranza@gmail.com</email>
</author>
<published>2016-03-09T18:17:56+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=459e44826b5d5499a3fbf0a4c5c78988fabd8481'/>
<id>459e44826b5d5499a3fbf0a4c5c78988fabd8481</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Add authorized keys bin script to find keys by fingerprint</title>
<updated>2016-03-24T20:48:27+00:00</updated>
<author>
<name>Pablo Carranza</name>
<email>pcarranza@gmail.com</email>
</author>
<published>2016-03-08T17:49:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=c9fac154cd99233c9a6f1cbb88316a476fffc3ad'/>
<id>c9fac154cd99233c9a6f1cbb88316a476fffc3ad</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Add ssh-key resource get to gitlab_net</title>
<updated>2016-03-24T20:48:27+00:00</updated>
<author>
<name>Pablo Carranza</name>
<email>pcarranza@gmail.com</email>
</author>
<published>2016-03-07T12:43:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=1f2bef765d8aa03b76f991178cfa7513833b4c3b'/>
<id>1f2bef765d8aa03b76f991178cfa7513833b4c3b</id>
<content type='text'>
This provides the integration point to the internal API to get the
ssh key from the internal API.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This provides the integration point to the internal API to get the
ssh key from the internal API.
</pre>
</div>
</content>
</entry>
<entry>
<title>Actually use the read_timeout config option</title>
<updated>2016-02-09T16:29:41+00:00</updated>
<author>
<name>Jacob Vosmaer</name>
<email>contact@jacobvosmaer.nl</email>
</author>
<published>2016-02-09T16:29:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=b963018eec171be99a2658b6ea38ba9f6cb5cb55'/>
<id>b963018eec171be99a2658b6ea38ba9f6cb5cb55</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Log duration of HTTP API requests</title>
<updated>2016-02-09T16:04:53+00:00</updated>
<author>
<name>Jacob Vosmaer</name>
<email>contact@jacobvosmaer.nl</email>
</author>
<published>2016-02-09T16:04:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=08c8f3085f414c669fd105e4494e2400c03146dc'/>
<id>08c8f3085f414c669fd105e4494e2400c03146dc</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Use an HTTP timeout of 5 minutes by default</title>
<updated>2016-02-09T16:04:29+00:00</updated>
<author>
<name>Jacob Vosmaer</name>
<email>contact@jacobvosmaer.nl</email>
</author>
<published>2016-02-09T16:04:29+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=e07469ff7bf3b65908fa2aeb572b56974133b25a'/>
<id>e07469ff7bf3b65908fa2aeb572b56974133b25a</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Add support to connect gitlab-shell to Unicorn via UNIX socket</title>
<updated>2015-11-10T17:33:24+00:00</updated>
<author>
<name>Kirill Smelkov</name>
<email>kirr@nexedi.com</email>
</author>
<published>2015-11-06T10:41:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=184385ac5b15ee8b7dc6fa5278f7e711de275921'/>
<id>184385ac5b15ee8b7dc6fa5278f7e711de275921</id>
<content type='text'>
It is well known that UNIX sockets are faster than TCP over loopback.

E.g. on my machine according to lmbench[1] they have ~ 2 times
lower latency and ~ 2-3 times more throughput compared to TCP over
loopback:

    *Local* Communication latencies in microseconds - smaller is better
    ---------------------------------------------------------------------
    Host                 OS 2p/0K  Pipe AF     UDP  RPC/   TCP  RPC/ TCP
                            ctxsw       UNIX         UDP         TCP conn
    --------- ------------- ----- ----- ---- ----- ----- ----- ----- ----
    teco      Linux 4.2.0-1  13.8  29.2 26.8  45.0  47.9  48.5  55.5  45.

    *Local* Communication bandwidths in MB/s - bigger is better
    -----------------------------------------------------------------------------
    Host                OS  Pipe AF    TCP  File   Mmap  Bcopy  Bcopy  Mem   Mem
                                 UNIX      reread reread (libc) (hand) read write
    --------- ------------- ---- ---- ---- ------ ------ ------ ------ ---- -----
    teco      Linux 4.2.0-1 1084 4353 1493 2329.1 3720.7 1613.8 1109.2 3402 1404.

The same ratio usually holds for servers.

Also UNIX sockets, since they reside on filesystem, besides being faster with
less latency, have one another nice property: access permissions to them are
managed the same way access to files is.

Because of lower latencies and higher throughput - for performance reasons, and
for easier security, it makes sense to interconnect services on one machine via
UNIX sockets and talk via TCP only to outside world.

All internal services inside GitLab can talk to each other via UNIX socket
already and only gitlab-shell was missing support to talk to Unicorn via UNIX
socket.

Let's teach gitlab-shell to talk via UNIX sockets.

[1] http://www.bitmover.com/lmbench/

~~~~

In this patch we

- add URI::HTTPUNIX to handle http+unix:// URI scheme
- add Net::HTTPUNIX to handle "connect via unix socket and then talk http"
- adjust GitlabNet#http_client_for() accordingly
- adjust documentation in config.yml.example

The http+unix:// scheme is not reinvented anew: the idea about its structure is
quite logical an was already established at least in requests-unixsocket python
package:

    http://fixall.online/theres-no-need-to-reinvent-the-wheelhttpsgithubcommsabramorequests-unixsocketurl/241810/
    https://github.com/msabramo/requests-unixsocket
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is well known that UNIX sockets are faster than TCP over loopback.

E.g. on my machine according to lmbench[1] they have ~ 2 times
lower latency and ~ 2-3 times more throughput compared to TCP over
loopback:

    *Local* Communication latencies in microseconds - smaller is better
    ---------------------------------------------------------------------
    Host                 OS 2p/0K  Pipe AF     UDP  RPC/   TCP  RPC/ TCP
                            ctxsw       UNIX         UDP         TCP conn
    --------- ------------- ----- ----- ---- ----- ----- ----- ----- ----
    teco      Linux 4.2.0-1  13.8  29.2 26.8  45.0  47.9  48.5  55.5  45.

    *Local* Communication bandwidths in MB/s - bigger is better
    -----------------------------------------------------------------------------
    Host                OS  Pipe AF    TCP  File   Mmap  Bcopy  Bcopy  Mem   Mem
                                 UNIX      reread reread (libc) (hand) read write
    --------- ------------- ---- ---- ---- ------ ------ ------ ------ ---- -----
    teco      Linux 4.2.0-1 1084 4353 1493 2329.1 3720.7 1613.8 1109.2 3402 1404.

The same ratio usually holds for servers.

Also UNIX sockets, since they reside on filesystem, besides being faster with
less latency, have one another nice property: access permissions to them are
managed the same way access to files is.

Because of lower latencies and higher throughput - for performance reasons, and
for easier security, it makes sense to interconnect services on one machine via
UNIX sockets and talk via TCP only to outside world.

All internal services inside GitLab can talk to each other via UNIX socket
already and only gitlab-shell was missing support to talk to Unicorn via UNIX
socket.

Let's teach gitlab-shell to talk via UNIX sockets.

[1] http://www.bitmover.com/lmbench/

~~~~

In this patch we

- add URI::HTTPUNIX to handle http+unix:// URI scheme
- add Net::HTTPUNIX to handle "connect via unix socket and then talk http"
- adjust GitlabNet#http_client_for() accordingly
- adjust documentation in config.yml.example

The http+unix:// scheme is not reinvented anew: the idea about its structure is
quite logical an was already established at least in requests-unixsocket python
package:

    http://fixall.online/theres-no-need-to-reinvent-the-wheelhttpsgithubcommsabramorequests-unixsocketurl/241810/
    https://github.com/msabramo/requests-unixsocket
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #212 from jirutka/patch-1</title>
<updated>2015-04-10T18:03:37+00:00</updated>
<author>
<name>Dmitriy Zaporozhets</name>
<email>dmitriy.zaporozhets@gmail.com</email>
</author>
<published>2015-04-10T18:03:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/gitlab/gitlab-shell.git/commit/?id=46b92499f1778775e31a1c27cfd1013586cd9cdf'/>
<id>46b92499f1778775e31a1c27cfd1013586cd9cdf</id>
<content type='text'>
Allow to configure location of the secret file</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Allow to configure location of the secret file</pre>
</div>
</content>
</entry>
</feed>
