Review the Replay Results

 

Applies To: SQL Server 2016

After the Microsoft SQL Server Distributed Replay feature completes a distributed replay, the replay activity for each client can be captured and saved in result trace files on each client. In order to capture this activity, you must use the -o parameter when you run the administration tool with the replay option. For more information about the replay option, see Replay Option (Distributed Replay Administration Tool).

The location of where the result trace files are stored is specified by the <ResultDirectory> XML element in the client configuration file, DReplayClient.xml, located on each client. The trace files in the client result directory are overwritten on each replay.

To specify what kind of output should be captured in the result trace files, modify the replay configuration file, DReplay.exe.replay.config. You can use the <OutputOptions> XML element to specify whether the row count or result set contents should be recorded.

For more information about these configuration settings, see Configure Distributed Replay.

The following table lists all of the event classes that are captured in the result trace data.

CategoryEventClass NameCapture FrequencyPoint of Capture
Replayable EventsAudit LoginOne time for each Audit Login event in the original trace dataUpon successful completion or failure of the event
Audit LogoutOne time for each Audit Logout event in the original trace dataUpon successful completion or failure of the event
SQL:BatchCompletedOne time for each SQL:BatchStarting event in the original trace dataUpon successful completion or failure of the event
RPC:CompletedOne time for each RPC:Starting event in the original trace dataUpon successful completion or failure of the event
Statistics and ResultsReplay Settings EventOne timeFirst event of the result trace
Replay Statistics EventOne timeLast event of the result trace
Replay Result Set EventOne time for each SQL:BatchStarting and RPC:Starting event.

Only captured if the value of the <RecordResultSet> option in the replay configuration file was set to Yes.
Replay Result Row EventOne time for each row in the result set for SQL:BatchStarting and RPC:Starting events.

Only captured if the value of the <RecordResultSet> option in the replay configuration file was set to Yes.
Errors and WarningsReplay Internal ErrorOne time for each internal errorUpon internal error condition
Replay Provider ErrorOne time for each provider errorUpon provider error condition

Note the following:

  • For each event that is successfully replayed on the target server, there is one corresponding output event class.

  • For each event failure or cancellation, there may be multiple errors that are generated.

The following figure lists which columns of the result trace are available for each type of event class that is captured during the replay.

Event class column mapping

The following table describes the columns of the result trace data.

Data Column NameData TypeDescriptionColumn ID
EventClassnvarcharThe name of the event class.1
EventSequencebigintFor provider errors, and internal errors and warnings, this is the capture event sequence that corresponds to the error or warning.

For all other event classes, this is the sequence of the event in the original trace data.
2
ReplaySequencebigintFor provider errors, and internal errors and warnings, this is the replay event sequence that corresponds to the error or warning.

For all other event classes, this is the sequence of the event that is assigned during replay.
3
TextDatantextThe content of TextData depends on the EventClass.

For Audit Login and ExistingConnection, this is the set options for the connection.

For SQL:BatchStarting, this is the body of the batch request.

For RPC:Starting, this is the stored procedure that was called.

For Replay Settings Event, this column contains the settings that are defined in the replay configuration file.

For Replay Statistics Event, this contains the following information:

-The replay target SQL server

-Total number of replayable events

-The number of provider errors

-The number of internal errors

-Internal warnings

-Total number of errors

-Overall pass rate

-The replay time (HH:MM:SS:MMM)

For Replay Result Set Event, this shows the list of return result column headers.

For Replay Result Row Event, this shows the return value of all columns for that row.

For Replay Internal Warning and Replay Provider Error, this column contains the provider warnings or errors.
4
AttentionbigintThe attention duration (in microseconds) for the event. This is calculated from the Attention event from the capture trace. If there was no query time-out specified for the event, this column is not populated (null).5
SubmitTimedatetimeThe time when the event was submitted to SQL Server.6
IsSuccessfulintA Boolean flag that indicates whether a particular event was successfully executed, and that result sets were returned to the client-side.

An event that generates a warning (such as when an event is cancelled because of Attention or a user-specified time-out) is considered successful.

IsSuccessful can be one of the following:

1 = successful

0 = failed
7
Duration [microsec]bigintResponse time duration (in microseconds) for the event. The measurement starts when the logon/log off/RPC/Language event was submitted to SQL Server.

If the event succeeds, the measurement ends when the complete result set has been consumed.

If the event does not succeed, the measurement ends at the time of event failure or cancellation.
8
RowCountbigintPopulated depending on the value of <RecordRowCount> in the replay configuration file:

If <RecordRowCount> equals Yes, this cell contains the number of rows in the result set that are returned by SQL Server.

If <RecordRowCount> equals No, this cell is not populated (null).
9
CaptureSPIDintThe ID of the capture session for the event.10
ConnectionIDintThe ID of the capture connection for the event.11
ReplaySPIDintThe ID of the replay session for the event.12
DatabaseNamenvarcharThe name of the database in which the user statement is running.13
LoginNamenvarcharThe user login name. This can be either a SQL Server security login or the Microsoft Windows login credentials, in the format domain_name\user_name.14
CaptureHostNamenvarcharThe name of the computer on which the client service is running during capture.15
ReplayHostNamenvarcharThe name of the computer on which the client is running during replay.16
ApplicationNamenvarcharThe name of the client application that created the SQL Server connection during capture.17

SQL Server Distributed Replay
Distributed Replay Requirements
Administration Tool Command-line Options (Distributed Replay Utility)
Configure Distributed Replay

Community Additions

ADD
Show: