Record and Analyze Workbook Performance
Your workbook is done and you’re wondering if its performance is taking a little longer than it should. To find out what’s slowing it down, you can use a performance recording to evaluate your workbook. This is an especially good idea if you plan to share or publish the workbook.
The Performance Recording feature in Tableau records performance information about key events as you interact with a workbook. You can then view performance metrics in a workbook that Tableau creates to analyze and troubleshoot different events that are known to affect performance:
Connections to data sources
Server rendering (Tableau Server only)
Tableau support may ask that you create a performance workbook as they work with you to diagnose performance issues.
Create a performance recording in Tableau Desktop
To start recording performance, follow this step:
Help > Settings and Performance > Start Performance Recording
To stop recording and view a temporary workbook containing results from the recording session, follow this step:
Help > Settings and Performance > Stop Performance Recording
You can now view the performance workbook and begin your analysis.
Click File > Save to save the workbook to the location you choose. If you're sending the recording to Tableau Support, save this workbook as a packaged workbook (.twbx) file, and then send it.
Interpret a performance recording workbook
A performance recording workbook contains two main dashboards: Performance Summary and Detailed Views. The Performance Summary dashboard provides a high-level overview of the most time-consuming events. The Detailed Views dashboard provides a lot more detail and is intended to be used by advanced users when building workbooks. The Detailed Views dashboard is only visible when the performance recording workbook is opened using Tableau Desktop.
The Performance Summary dashboard contains three views: Timeline, Events, and Query.
The uppermost view in the performance summary recording dashboard shows the events that occurred during recording, arranged chronologically from left to right. The bottom axis shows elapsed time since Tableau started, in seconds.
In the Timeline view, the Workbook, Dashboard, and Worksheet columns identify the context for events. The Event column identifies the nature of the event, and the final column shows each event’s duration and how it compares chronologically to other recorded events:
The middle view in a performance summary dashboard shows the events, sorted by duration (greatest to least). Events with longer durations can help you identify where to look first if you want to speed up your workbook.
Different colors indicate different types of events. The range of events that can be recorded is:
If layouts are taking too long, consider simplifying your workbook.
Connecting to data source
Slow connections could be due to network issues or issues with the database server.
This event captures the amount of time spent by Tableau in generating the queries. Long compile query times indicate that the queries generated are complex. The complexity may be due to too many filters, complex calculations, or generally due to a complex workbook. Examples of complex calculations include, lengthy calculations, LOD calculations, or nested calculations. Try simplifying the workbook, using action filters or moving calculations to the underlying database.
For live connections, if queries are taking too long, it could be because the underlying data structure isn’t optimized for Tableau. Consult your database server’s documentation. As an alternative, consider using an extract to speed performance.
For extracts, if queries are taking too long, review your use of filters. If you have a lot of filters, would a context filter make more sense? If you have a dashboard that uses filters, consider using action filters, which can help with performance.
To speed up extract generation, consider only importing some data from the original data source. For example, you can filter on specific data fields, or create a sample based on a specified number of rows or percentage of the data.
To speed up geocoding performance, try using less data or filtering out data.
To speed up data blending, try using less data or filtering out data.
You can speed up server rendering by running additional VizQL Server processes on additional machines.
If you click on an Executing Query event in either the Timeline or Events section of a performance summary dashboard , the text for that query is displayed in the Query section.
If you are connected to a published data source, the query text is displayed in XML. If you are connected to the data source directly, the query is displayed in SQL like shown below:
If it makes sense, you can use the query text to work with your database team on optimizing at the database level. Sometimes the query is truncated and you’ll need to look in the Tableau log to find the full query. Most database servers can give you advice about how to optimize a query by adding indexes or other techniques. See your database server documentation for details.
Sometimes for efficiency, Tableau combines multiple queries into a single query against the data. In this case, you may see an Executing Query event for the Null worksheet and zero queries being executed for your named worksheets.
This view is the detailed version of the Timeline view that shows all events and separating individual items that were grouped in the Timeline view. It is intended to be used by advanced users during workbook designs.
The Detailed Views dashborad contains Depth, Exclusive CPU, Inclusive CPU, and Elapsed Time views.
The Depth view is the uppermost view in the Detailed Views dashboard and provides insight into what happens when a request is made. This view is the most useful when filtered to a single user request. Examples of user requests are: loading a view, selecting a mark, or changing a filter.
Each bar on the depth view represents a single activity. An activity is a unit of work that is done as part of processing a user request. A single user request results in multiple activities. The length of each bar on the depth view is proportional to the elapsed time for the activity that the bar represents.
High level activities appear at the top of the view. Activities lower down are child activities generated by high level activities.
Hovering over each bar provides additional details about the activity and also highlights the corresponding row in the CPU and Elapsed Time view described in the next section.
In order to narrow down on what parts of the request took the most time, investigate long running activities at the highest levels.
CPU and Elapsed Time
The CPU and Elapsed Time views appear lowermost in the Detailed Views dashboard. You can toggle between Exclusive CPU, Inclusive CPU and Elapsed Time views by clicking on the radio buttons.
While the Depth view can help in quick visual identification of long running activities, it may not necessarily highlight activities that happen multiple times with each instance taking a small amount of time. The Exclusive CPU, Inclusive CPU, and the Elapsed Time views provide aggregate statistics for each activity. The number of times an activity took place is shown in the Count column and the total amount of time taken by a single activity is shown using the bar chart.