GoEddie / SQLCover

Apache License 2.0
63 stars 53 forks source link

Simplify SQL Trace Data #50

Closed tgruetzm closed 4 years ago

tgruetzm commented 4 years ago

Fixes # .

Changes proposed in this pull request: Removed tsql_stack and plan_handle from the trace. The tsql_stack and to a lesser degree the plan_handle don't appear to be used. They also cause the trace to be significantly larger. In our database running 500 tests(we're just getting started too) results the trace file was over 1GB. Removing these two fields drops down to 100MB.

DatabaseGateway.GetTraceRecords(...) doesn't copy the tsql_stack or plan_handle data anywhere, EventsParser.Get2008StyleString does reference tsql_stack but the event xml does not contain this field since GetTraceRecords doesn't copy it.

How to test this code:

Run a trace over SQL cover session and verify coverage files Has been tested on (remove any that don't apply):

SQL Server 2016