Execution Flow
This is an internal helper function — it is called by functions that accept an
-EventLog switch (e.g. New-sqmAvailabilityGroup) via Write-sqmSetupEvent. The SVG step visualizer supports render types: flow-arrows, disk-format, node-restart, data-replicate, listener, gears, and a default fallback. Returns $null if the event file is missing or contains no valid JSON-Lines events.Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| -EventPath | String | Required | Path to the JSON-Lines event file written by Write-sqmSetupEvent. |
| -OutputPath | String | Optional | Output HTML file path. Default: <EventPath>.html. |
| -Title | String | Optional | Page title shown in the report header. Default: SQL Server Setup. |
| -Server | String | Optional | Server name shown in the report. Default: $env:COMPUTERNAME. |
Return Value
Returns a String containing the full path to the written HTML report file, or $null if no valid events were found or the event file does not exist.
Examples
Example 1 — Build report from an event log
$reportPath = New-sqmSetupReport -EventPath "C:\Logs\ag-setup.jsonl"
Start-Process $reportPath
Example 2 — Custom title and output path
New-sqmSetupReport -EventPath "C:\Logs\ag-setup.jsonl" -OutputPath "C:\Reports\AG-Prod-Setup.html" -Title "AG-Prod Setup" -Server "SQL01"