SyncTracer Class
Provides tracing for a synchronization session, with four levels of output: errors, warnings, informational, and verbose.
Inheritance Hierarchy
System.Object
Microsoft.Synchronization.Data.SyncTracer
Namespace: Microsoft.Synchronization.Data
Assembly: Microsoft.Synchronization.Data (in Microsoft.Synchronization.Data.dll)
Syntax
'Declaration
Public NotInheritable Class SyncTracer
'Usage
public static class SyncTracer
public ref class SyncTracer abstract sealed
[<AbstractClassAttribute>]
[<SealedAttribute>]
type SyncTracer = class end
public final class SyncTracer
The SyncTracer type exposes the following members.
Methods
Name | Description | |
---|---|---|
Error(String) | Generates an error trace when a message parameter is specified. | |
Error(Int32, String) | Generates an error trace when the indentLevel and message parameters are specified. | |
Error(String, Object[]) | Generates an error trace when the format and args parameters are specified. | |
Error(Int32, String, Object[]) | Generates an error trace when the indentLevel, format, and args parameters are specified. | |
Info(String) | Generates an informational trace when a message parameter is specified. | |
Info(Int32, String) | Generates an informational trace when the indentLevel and message parameters are specified. | |
Info(String, Object[]) | Generates an informational trace when the format and args parameters are specified. | |
Info(Int32, String, Object[]) | Generates an informational trace when the indentLevel, format, and args parameters are specified. | |
IsErrorEnabled | Returns whether an error trace will be included in the output. | |
IsInfoEnabled | Returns whether an informational trace will be included in the output. | |
IsVerboseEnabled | Returns whether a verbose trace will be included in the output. | |
IsWarningEnabled | Returns whether a warning trace will be included in the output. | |
Verbose(String) | Generates a verbose trace when a message parameter is specified. | |
Verbose(Int32, String) | Generates a verbose trace when the indentLevel and message parameters are specified. | |
Verbose(String, Object[]) | Generates a verbose trace when the format and args parameters are specified. | |
Verbose(Int32, String, Object[]) | Generates a verbose trace when the indentLevel, format, and args parameters are specified. | |
Warning(String) | Generates a warning trace when a message parameter is specified. | |
Warning(Int32, String) | Generates a warning trace when the indentLevel and message parameters are specified. | |
Warning(String, Object[]) | Generates a warning trace when the format and args parameters are specified. | |
Warning(Int32, String, Object[]) | Generates a warning trace when the indentLevel, format, and args parameters are specified. |
Top
Remarks
Tracing involves recording application operations, data, and metadata, and providing this information to a listener. A listener frequently writes trace information to a file, but could also handle the information in other ways. Sync Framework includes tracing for the client and server synchronization providers. In distributed applications, tracing can be very important because it enables you to troubleshoot issues that might otherwise be difficult to discover.
Tracing in Sync Framework is composed of the following components:
A tracing infrastructure that is based on the .NET Framework implementation of tracing, specifically the TraceListener class. The most important operations of the client and server providers are traced, and key metadata is provided to one or more listeners.
The SyncTracer object. This enables you to determine which level of tracing is enabled and to write messages to the trace output based on application events.
For more information, see Tracing the Synchronization Process.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.