Quick Start Guide - Trace Data Visualization
FB TraceManager 3 supports four different ways to visualize the received trace output data.
• | Raw |
• | Parsed |
• | Statistic |
• | Hotspots (New in V3.0) |
The supported trace data visualization modes depend on the edition you use. For example, the Lite Edition only supports the Raw mode, whereas the Standard Edition supports additionally Parsed and Statistic. Enterprise Edition also supports Hotspots Analysis. See also the Product Editions section.
Raw
In the Raw tab, the "pure" received trace data is shown as it comes from the server. This is pretty much what you see when using Firebird's fbtracemgr command-line utility, but the raw output visualization in FB TraceManager offers much more than simple text output.
In the Settings flyout toolbar you can disable or pause raw visualization. You can save the output to the FB TraceManager 3 database. Saved trace data can be accessed with the Browse module at a later point. When the Dismiss When Paused option (available only, if Paused is selected) is selected, then received data is removed from the processing queue, without adding trace data to the raw output.
New in V3.0: The new Disabled setting tells the trace data background worker thread to NOT put anything into the processing queue at all, while On-The-Fly aggregation for Hotspots Analysis is still enabled. This results in a very light-weight trace session with the capabilities to inspect executed statements, procedures/functions and/or triggers via the Hotspots tab.
The Max Lines setting enables you to configure a purge strategy for the raw output. Once the threshold is reached, the raw memo is completely cleared. This is necessary to allow FB TraceManager running in a 24x7 scenario, without increasing memory usage steadily.
Beside that, the raw output facility has the following advanced capabilities:
• | Line numbers are shown |
• | The background color of a raw line which marks a new trace event can be set with a custom color |
• | Syntax highlighting is enabled for SQL in general and for trace event types (PREPARE_STATEMENT, CLOSE_CURSOR etc.) |
• | You now can collapse/expand (folding) the raw output of entire trace event blocks |
• | Define custom bookmarks in the raw output via CTRL + SHIFT + [1..9] and locate them with CTRL + [1..9] |
• | It's also easy to navigate to the parsed trace event for the raw trace event at the current cursor position by using the context menu |
Right-clicking in the raw output pops up a context menu with a Go To Parsed Event menu item to navigate to the parsed trace event for the current cursor position immediately.
Parsed
The included context-based parser transforms the received raw data into a structured form. This will give you a much better understanding of what trace events have occurred with additional event-specific data like e.g. the isolation level, when we are talking about a START_TRANSACTION event type. Each trace event type has its own set of detailed data. The parser will handle each trace event type accordingly and displays the parsed data in the data grid.
Again, you can pause and clear the parsed output. Clearing will not delete trace data stored in the database. If the parsed output is paused/suspended, incoming events are queued and processed when the parsed output is resumed, if Dismiss When Paused is not selected.
When the Dismiss When Paused option (available only, if Paused is selected) is selected, then received data is removed from the processing queue, without adding trace data to the parsed output.
If the Log to Database option is selected, then parsed data is stored in the included FBTM3.fdb database automatically. Saved trace data can be accessed with the Browse module at a later point. The Commit every <N> records option allows you to specify a commit interval for the process of trace data storage. If you want to make logged trace data visible for other transactions immediately, then click the Commit Now button.
New in V3.5: Starting with V3.5, the task of persisting parsed data in the database is asynchronous to the trace data fetcher background worker thread. At a fixed interval of 10 seconds a periodic worker is responsible for flushing parsed data into the database. This increases trace fetching throughput by up to 250%.
New in V3.0: The new Disabled setting tells the trace data background worker thread to NOT put anything into the processing queue at all, while On-The-Fly aggregation for Hotspots Analysis is still enabled. This results in a very light-weight trace session with the capabilities to inspect executed statements, procedures and/or triggers via the Hotspots tab.
The Max Rows and Purge Rows option allow you to configure an automatic purge strategy for rows in the grid. For example, if the row count reached a threshold of 100000, the 10000 oldest rows are removed automatically. This makes FB TraceManager capable to run in 24x7 requirements, without exhausting the available memory. Tests have shown, that a rough estimation for memory usage in FB TraceManager is:
~100 MB memory for ~20000 parsed trace events with ~150000 raw lines
Of course, this depends a lot on the trace event types, what detailed trace data is available etc.
Other things you can do in the parsed output are:
• | All columns are sortable by simply clicking on the grid column header. |
• | A footer band allows you to execute an aggregate function (avg, count, count distinct, max, min, sum) per numeric column independently. The aggregate function can be chosen with a context menu on the column in the footer. |
Left-click on a footer column to refresh the aggregation.
• | The Keep Selection option allows you to keep the selection/focus on the currently selected row, even if new records are added during a trace session. |
• | Double-click in the parsed output grid or use the context menu to locate the selected trace event in the raw output.![]() |
• | Regular expression support for filtering textual columns. This is a very powerful and flexible way to filter already fetched and incoming trace data. Regular expressions are only applied to the visual output of the parsed trace data grid, but currently not for filtering to omit storing particular trace data in the FB TraceManager 3 database. Several column-based regular expression filters are combined with the logical AND operator. The Case-sensitive regex filter option specifies whether the regular expression filters should be applied case-sensitive or not. To apply a regular expression filter, simply enter a valid regular expression in the appropriate column header area and press ENTER. You find some hints regarding the supported syntax and simple examples in the Regular Expressions chapter. |
• | The Clear regex filter button allows you to clear the entire regex filter definition in each columns in one step. |
• | Filtered columns are marked with a special icon in the column header. |
• | The Reload Event Processing Rules button reloads the defined rules of the event processing engine for this particular started trace session. The reloaded event rules are applied to newly received parsed trace data rows. See Event Processing for further details on what you can do with event processing. |
• | The Disable Event Processing option allows you to disable event processing for the currently running trace session, without disabling event rules globally. |
• | You can copy a column value via the context menu to the clipboard by using the Copy menu item. You will see context-based submenu items with column names, where the column value is not empty![]() |
• | Grid column states are now persisted into the file system. This includes: column width, position, visible/invisible and sort order |
• | If you close the Trace Data Visualization tab of a running project, you get asked to commit/rollback an active parsed trace data transaction |
Statistic
This view gives you useful execution statistics on a per trace event level. All throughput measures here are directly related to the chosen GUI refresh interval.
• | Total Refresh Intervals: Total number of executions of the GUI refresh timer. |
• | Refresh Intervals with Event: Total number of executions of the GUI refresh timer where this particular trace event has been seen. |
• | Total Executions: Total number of occurrences for this particular trace event. |
• | Last Interval Executions: Number of executions in the last interval. Changes only if interval executions > 0. |
• | Min Count / Interval: Number of minimum executions in the last interval. Changes only if interval executions > 0. |
• | Max Count / Interval: Number of maximum executions in the last interval. Changes only if interval executions > 0. |
• | Avg Count / Interval: Number of average executions in the last interval. Changes only if interval executions > 0. |
Hint: The per trace event statistic overview has been improved in V3.5 a lot.
Hotspots (New in V3.0)
To learn more about this type of visualization, check out the Hotspots Analysis section.
See also