Traffic Watch: Configuration
-
The following configuration keys control Traffic Watch's log-to-file behavior.
They filter the log-to-file output only, and do not affect the live stream. -
Learn how to set these keys in the configuration overview.
-
In this article:
Traffic Watch configuration keys
TrafficWatch.Mode controls whether Traffic Watch logs requests to file, and the other keys filter the log output.
Requests can be filtered by database, response status code, HTTP method, change type, client certificate, request or response size, and duration.
TrafficWatch.Mode
Sets whether Traffic Watch writes requests to the log file.
Set to ToLogFile to enable logging to file, or Off to disable it.
- Type:
enum TrafficWatchMode(Off,ToLogFile) - Default:
Off - Scope: Server-wide only
TrafficWatch.Databases
Only requests made to the listed databases are logged.
Provide a semicolon-separated list of database names; when left empty, requests to all databases are logged.
e.g., northwind;another-database
- Type:
string[] - Default:
null - Scope: Server-wide only
TrafficWatch.StatusCodes
Only requests that returned one of the listed HTTP response status codes are logged.
Provide a semicolon-separated list; when left empty, requests with any status code are logged.
e.g., 200;404;500
- Type:
HashSet<int> - Default:
null - Scope: Server-wide only
TrafficWatch.MinimumResponseSizeInBytes
Only requests with a response of at least this many bytes are logged.
- Type:
int - Default:
0 - Min Value:
0 - Scope: Server-wide only
TrafficWatch.MinimumRequestSizeInBytes
Only requests with a request body of at least this many bytes are logged.
- Type:
int - Default:
0 - Min Value:
0 - Scope: Server-wide only
TrafficWatch.MinimumDurationInMs
Only requests that took at least this many milliseconds to process are logged.
- Type:
int - Default:
0 - Scope: Server-wide only
TrafficWatch.HttpMethods
Only requests made with one of the listed HTTP methods are logged.
Provide a semicolon-separated list; when left empty, requests with any HTTP method are logged.
e.g., GET;POST
- Type:
string[] - Default:
null - Scope: Server-wide only
TrafficWatch.ChangeTypes
Only requests with one of the listed change types are logged.
A request's change type is the category of operation it performs, such as a query, a document operation, or a subscription.
Provide a semicolon-separated list; when left empty, requests with any change type are logged.
e.g., Queries;Documents
- Type:
TrafficWatchChangeType[] - Default:
null - Scope: Server-wide only
Possible values:
None, Queries, Operations, MultiGet, BulkDocs, Index, Counters, Hilo, Subscriptions, Streams, Documents, TimeSeries, Notifications, ClusterCommands
TrafficWatch.CertificateThumbprints
Only requests made with one of the listed client certificate thumbprints are logged.
Provide a semicolon-separated list; when left empty, requests with any thumbprint are logged, as well as those made without a client certificate.
- Type:
string[] - Default:
null - Scope: Server-wide only