SQL Server Concurrency
- Part One: Future Proofing for Concurrency
- Part Two: Look at Blocked Process Reports Collected With Extended Events
- Part Three
I just met a friend at a SQL Saturday who let me know that he recognizes my name because it was attached to a project I wrote five years ago. The “Blocked Process Report Viewer”. I was impressed. I’m glad to know that it’s still used. So I decided to update it for 2016.
I’ve extended the Blocked Process Report Viewer to look at blocked process reports that were collected with extended events session.
Where To Find It
The code for the procedure is where it always is on CodePlex at https://sqlblockedprocesses.codeplex.com/:
How To Use It
The viewer can consume blocked process report events captured by any extended events session as long as that session has a target of ring_buffer
or event_file
. For example, if you set up your extended events session the way Jeremiah Peschka did in Finding Blocked Processes and Deadlocks using SQL Server Extended Events. Then you would use the viewer like this:
exec sp_blocked_process_report_viewer @Source ='blocked_process', -- the name that Jeremiah gave to his xe session @Type ='XESSSION'; |
which gives you something like
The value of the blocked process report viewer is that it organizes all the blocked processes into “episodes”. Each episode has a lead blocker which is the process in the front of the traffic jam. Look at that process closely.
Feedback
Let me know how it goes. Tell me if there are any errors or performance issues. I’m especially interested in the performance of the viewer when given extended events sessions that use ring_buffer
targets.