Filtering Folders or Files

By default, when an Agent creates a new Job or links to a Job, the Agent synchronizes its files and folders with the Vault. Using filters, you can exclude certain files, file types, or folders from being replicated. You can set the filter parameters for each Job, and can specify filter parameters on the Agent that apply to all Jobs defined on that Agent.

The filters are stored as XML files in a folder called Filter in the in the Agent installation folder (by default C:\Program Files\Globalscape\WAFS Agent). These filter files can be copied from one Agent to another so that you do not have to redefine them for each Agent.

In some cases, the filtering functionality may be used to increase the performance of the WAFS system by filtering out unnecessary files. Such files might include temporary files ("*.tmp") that are often used temporarily while performing a save operation. When handling I/O requests for filtered files, the Agent can skip expensive operations such as network communications with the Vault. This reduction in expensive operations can lead to performance gains.

Note that incorrectly filtering out files may lead to unexpected behavior within user applications. Care should be taken when adding or modifying the set of filters through careful testing.

Creating Filters

You can create Filters on the Agent that apply to all Jobs defined on that Agent and on individual Jobs. (To remove a filter, refer to Removing Filters.)

To define a filter

  1. Open the WAFS Agent Manager and click the Agent or Job on which you want to define the filter.

  2. Click the Filters tab.

  3. In the File Filters area, define the filter pattern for those files that you do NOT want to replicate:

    Examples of file filter patterns:

    *.bak - Will not replicate files that end with .bak extension

    tmp* - Will not replicate files that start with "tmp"

    *.mp? - Will not replicate files with an extension of .mpX, where X is any one character.

  4. Click Add. The filter pattern is displayed.

  5. In the Folder Filters area, define the folder filter pattern for those folders that you do NOT want to replicate (i.e., none of the files in the folder will be replicated).

    Examples of folder filter patterns:

    *temp* - Excludes any folder that has "temp" in its name

    \Local? - Excludes any folder in the job root folder that starts with "Local" and has exactly one character at the end (e.g., "Local7")

  6. Click Add. The filter pattern is displayed.

  7. Click Save to save the changes.

Removing Filters

To remove a filter

  1. Open the WAFS Agent Manager and select the Agent or Job from which you want to remove the filter.

  2. Click the Filters tab.

  3. Click the filter pattern that you want to remove, then click Remove.

  4. Click Save to save the changes. The files and/or folders that were not being replicated will now replicate.