Benchdog SQL Watchdog
A VS Code extension for watching SQL Server and Azure SQL. Every server of a project shows how it is at a glance, coloured green, amber or red, and opens on a page with its health, top queries, inventory and history. The alerts the collector keeps open are listed beside them. All the work is done by the Benchdog engine (benchdog serve); this extension is the screen.

Your estate beside your code.

One file says what to watch, never how to get in.
Install
Install it from the Marketplace in VS Code. The Benchdog engine ships inside the package for Windows (x64), so there is nothing else to install and no .NET needed. Mac and Linux are coming. The desktop app and the benchdog command for the same tool are at benchdog.dev.
What it does
- Estate view: a SQL Watchdog panel in the activity bar lists every
.monitor.json project in the workspace, and any you open from elsewhere, each with its servers under it and its history store. A server's icon and line say how it is: green fine, amber a warning, red critical, grey not reached or not checked yet. With a history store, it shows what the collector last saw; Check Now and Check All Now check from VS Code straight away.
- Open Overview (the dashboard button on a project, or in the editor's title bar for a
.monitor.json): every server of the project a card in its group, coloured by how it is, with its line and a line each of its waits, CPU and disk I/O over the last hour from the history store, or from the checks run in VS Code without one. A card opens the server's page. Add Server asks for the group; it is kept in the project file. With a history store, the latest alerts of the last day are listed beside the cards, the latest change first; click one to open its server. The Versions tab shows the releases the servers run as a ring, how many are behind the latest update, how many stand each way, and each server with its update and build and what to do, from the history store or the checks run in VS Code.
- New Project (the + button) asks for a name, where to save the file, the first server and how to sign in to it, and whether to keep the history in a database. The + beside a project adds a server; right-click a server to remove it, or a project to set its history store.
- Server page: click a server to open it. Health shows each area as a card, those that need a look first: CPU, memory, waits, blocking, deadlocks, long queries, disk and log space, backups, failed jobs and availability groups, each with its details. Activity shows what the server was doing over the check's one second sample, each number a tile (batch requests, transactions, compilations, connections, tasks waiting, page life, page splits, waits, disk reads and writes, and more) with a line of the last hour from the store, or of the checks run here. Top queries reads them from the plan cache now, from a database's Query Store, or from what the collector kept, ordered by CPU, time, reads, writes or runs, and shows them as totals or per run, which ranks them by what each run took. Click a query to see all of it, with what it took in all and per run, and Copy it or open it in a new SQL editor. Show Plan shows its plan below it: each operator indented as a tree with its share of the cost, every warning in plain words, and the missing indexes, each with its CREATE INDEX statement to copy. Save Plan writes a .sqlplan for SQL Server Management Studio, and Open XML opens the plan in an editor. Inventory says what the server is, what it is patched to and when its support ends, what best practice says about its settings, databases and logins, worst first, and lists its databases, settings and powerful logins, or says why its databases could not be read, such as a lock held while one is made or dropped. History (with a store) starts with one chart of SQL Server's CPU, the memory in use and batch requests a second, with the same time a week ago dashed beneath while Compare with last week is ticked, and each line's latest value and its average a week ago; then it charts SQL Server's CPU, memory used, the least free disk and blocked sessions, and lists each check, to open in full. Data I/O lists each database file with its size, reads, writes and the average time each took since SQL Server started, the slowest first. Sessions lists the user sessions, those holding others up first, with who each is, what it runs and waits on, and who blocks whom. Backups shows each database's last 31 days a square a day, green a full backup, blue a differential, pale log backups only, with what it needs; hover a day for its backups. Each reads the server when first opened, and again with Read Again.
- Alerts view: every alert the projects' history stores keep open, the worst first. Click one to open its server.
- Test Project signs in to each server and the store as the collector would, and looks for each alert channel's secret. Save Alert Channel Secret keeps a channel's SMTP password or webhook address in the system's secure store, and Send Test Alert shows a channel works.
- Collector Service Status says whether the collector service is installed on this computer and running, and copies the command that installs it. Installing it needs an administrator, so it is done from a terminal (or with the scripts in
scripts/monitor), not from VS Code.
- Project files: open one to get IntelliSense, its problems in the Problems panel, and Check All Now and Test Project links at the top. A project file never holds a password or a secret.
- Sign in and SQL logins work as in the other Benchdog SQL tools: your Windows account for SQL Server on your network, your Benchdog account for Azure SQL, or a SQL login whose password Benchdog keeps until VS Code closes or, if you choose, in the system's secure store. The eye on the password box shows what you typed. Azure managed identity is for a collector running in Azure; checks from VS Code can not use it.
Settings
| Setting |
Does |
benchdogMonitor.enginePath |
Full path to the benchdog executable. Empty uses the one that ships with the extension. |
benchdogMonitor.tenant |
Tenant id to sign in to for servers that use Entra. Empty means your home tenant. |
benchdogMonitor.useAzureCli |
Sign in through your existing az login instead of the browser. |
benchdogMonitor.refreshMinutes |
How often the views read each history store again while they are open. 5 by default; 0 turns it off. Servers are only checked from VS Code when you ask. |
The settings are separate from the other Benchdog extensions', so they can all be installed together.
How it stays safe
- Every server is reached as you. The extension keeps only the paths of project files you opened from outside the workspace; never a password or a secret.
- Checks only read the server's own views. A check waits no longer than 5 seconds for a lock and gives way in a deadlock, so it never stops the server's own work.
- A channel's secret is given to the engine once and kept only in the system's secure store. It is never sent back, shown or logged. Error messages have values taken out. Names and values are set as text on the page, so nothing from a server can become markup. The page is thrown away when hidden.
Diagnostics
Turn on the benchdogMonitor.diagnostics setting to have the engine write a debug log of what it does, for finding out why something went wrong. Run Benchdog SQL Watchdog: Open Diagnostics Logs Folder to see the logs. Passwords, connection strings, tokens and your data are never written.
Trial and licence
Every Benchdog tool has a thirty day trial with every feature and no card: ask for one at benchdog.dev/trial. One licence is for one person and covers the VS Code extension, the desktop app and the command line, on every machine you work from. Prices are at benchdog.dev/pricing. The licence is checked offline; the tool contacts benchdog.dev only when you ask it to, never in the background. The terms are in LICENSE.md and at benchdog.dev/terms.
Help and support
Getting started, how to do the common jobs, the questions people ask and what to try when something goes wrong: benchdog.dev/help/sqlmonitor. Something else? The support form, or support@benchdog.dev, and a person replies.
| |