subversion-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Branko Čibej <>
Subject Re: Why so many open connections?
Date Fri, 12 Jul 2013 15:41:17 GMT
On 11.07.2013 18:04, Michael Pruemm wrote:
> Branko Čibej <brane <at>> writes:
>> No. Pools encapsulate all resource management -- including file handles
>> and sockets (connections), not only allocated memory.
>> This document explains how pools should be used:
>> In your example, you should be using an iteration pool.
> Yes, that's what I did. It was more that I was somehow expecting the "ls3"
> connection to be reused instead of always creating a new one.

The libsvn_client interface creates a new connection for each operation.
If you need complete control over connection management, you'll have to
use libsvn_ra.

> The document also says:
> "Whenever an unbounded iteration occurs, an iteration subpool should be used."
> What is considered "unbounded iteration" here? I always thought that "for i
> = 1 to N" was considered a bounded loop, and "while (condition)" unbounded.

"Unbounded" in this context is anything where the number of iterations
depends on some condition that is not known at compile-time. If the
number of iterations is constant, that's not unbounded. If it depends,
for example, on the number of modified files in a working copy, then it
is "unbounded" since you cannot predict an upper bound on the number of
iterations and, as a consequence, on the associated resource usage.

-- Brane

Branko Čibej | Director of Subversion
WANdisco // Non-Stop Data

View raw message