The TreeDeltaCompresionThreshold option

A collection of information about Vault, including solutions to common problems.

Moderator: SourceGear

Post Reply
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear

The TreeDeltaCompresionThreshold option

Post by jeremy_sg » Thu Jul 15, 2004 7:54 am

In the Vault.config file (which is installed with the server in c:\inetpub\wwwroot\VaultService by default) there is an option called TreeDeltaCompresionThreshold. By default, it is set to 1000. In order to understand how this setting affects the Vault server, it's necessary to understand how the Vault server communicates with the Vault client.

Upon a successful login, the first operation that the client performs is a Refresh. During a refresh, the status bar at the bottom of the GUI client will read "Retrieving Repository Structure." During the refresh, the client requests that the server send it all of the changes between the last version of the repository that the client has seen and the latest version that the server has. This "tree delta" looks something like this:

Code: Select all

Delete file.cs version 1
Add file.cs version 2
Some operations (like branch of a large directory structure) can result in large tree deltas. Also, the tree delta can be large if the client doesn't have an old version of the tree, so that the delta must include and "Add" operation for every item in the tree. If the number of nodes is greater than the number set in TreeDeltaCompresionThreshold, then the tree delta is compressed in order to save bandwidth. Sending compressed deltas has been shown to make the refresh operation much faster for large tree deltas. This is especially true for slow network connections.

One case where this setting can cause problems is where the server does not have enough memory to compress the delta. During the compression, the memory usage of the server will go up dramatically. If the usage goes past a certain limit, Windows will kill the server process, which is the aspnet_wp.exe process. Only some users will see this problem because only some clients will be requesting tree deltas that are larger than the TreeDeltaCompresionThreshold setting.

You may set TreeDeltaCompresionThreshold to 0 to disable compression of tree deltas.

Post Reply