On Thu, Jan 21, 2016 at 04:42:35PM +0100, 'Klaus Aehlig' via ganeti-devel wrote:
> Commit b0a7e3771bfd changed sending of JSON-encoded answers
> to standard String sending. This was necessary as converting
> Strings to ByteStrings, even to lazy ones, fully enforced the
> String before the first Char got out of scope and could be
> garbage collected.  The down-side of this approach is, that
> we now end up with one system call per character to be send.
> The good news, however, is that the library's buffering uses
> memory only a little more than a byte for a byte, so we can
> afford buffering in that layer. Do so to reduce the number of
> system calls.
> 
> On a, not quite realistic, test cluster, this resulted in the
> time for a config-read going down by 1.5 orders of magnitude
> with only small increase in residual memory.

I wonder is a 1MB buffer per socket a little aggressive? On a large-ish
cluster you might have connections open from each node and from each
running job, so this could add up quickly, especially if you've limited
RAM in dom0.

Cheers,
Brian

Reply via email to