Elastic Jobs
DBA Dash monitors the jobs of an elastic job agent through its job database - the Azure SQL Database the agent keeps its jobs and history in. Add the job database as a source connection, as for any other Azure database, and grant the service access to the agent’s jobs (below). There’s nothing else to enable.
Permissions
The service reads the views in the job database’s jobs schema. Add its login as a user of the job database and a member of the jobs_reader role:
/* In the job database */
CREATE USER DBADashService FOR LOGIN DBADashService;
ALTER ROLE jobs_reader ADD MEMBER DBADashService;For a Microsoft Entra identity, create the user with CREATE USER [name] FROM EXTERNAL PROVIDER instead.
Without jobs_reader the jobs views can’t be seen, so the database isn’t recognised as a job database and nothing is collected - there’s no error to say so. If an agent’s jobs don’t appear, check this first.
See Security for the permissions DBA Dash needs on Azure SQL Database generally.
Collection
The ElasticJobs collection runs every 2 minutes and is on by default. It only does anything on an Azure SQL Database where the jobs schema’s views can be read - checked once an hour, so a new agent is picked up within the hour. Other databases are skipped.
Each collection returns:
- Jobs, their steps (the current version) and the members of the target groups the steps run against - databases, servers, elastic pools and shard maps, included or excluded. Only when they’ve changed since they were last sent, and at least once an hour.
- Executions: the job’s executions and the execution of each step against each target. Executions are updated as they progress, so each collection returns those created since the previous one and any that were still running, and the repository updates them in place. The first collection after the service starts goes back 7 days.
Execution history is kept for 14 days and the hourly stats for 2 years by default. See Data Retention.
Where to find it
- An Elastic Jobs node on the job database, under its Azure server.
- An Elastic Jobs node on the Azure server, where any of its databases is a job database. With more than one job database on the server, the node shows the status of them all, with a node for each job database beneath it.
- The Jobs folder at the root and on tag group folders has an Elastic Jobs tab where there are elastic jobs in scope.
An agent’s node has three tabs:
- Elastic Jobs - the status of each job, with its schedule, last execution and message, failures and durations. History lists the job’s executions; Targets on an execution shows how each step went against each target. Steps shows the job’s steps, commands and the members of their target groups.
- Timeline - the job’s executions over the selected period. Steps adds a row for each step, with a bar for each run of the step - from the first target starting to the last finishing, coloured by the worst outcome. Expand a step for a row per target database. The tooltip names the target, and for a run lists its targets by outcome (e.g. 2: 1 skipped, 1 succeeded). Double-click a bar for the execution’s targets.
- Job Stats - executions, failures, retries, skipped executions and durations for each job and step, with a chart over time. A step’s counts are of its executions against each target.
The Elastic Jobs tab shows the Snapshot Date and Snapshot Age of the job database’s collection, highlighted by how overdue it is, so you can see how current the jobs and their status are.
Start and stop jobs
Right-click a job on the Elastic Jobs tab for the Elastic Job Actions menu: History, and Start Job or Stop Job. Stop cancels one execution, or every active execution of the job. The dialog follows the execution it started or stopped, refreshing every 10 seconds until it completes.
Starting and stopping go through messaging, so they need:
- The job allowed by Allowed Job Execution in the service configuration tool - the same list as SQL Agent jobs, matched on the job’s name or ID. Disabled by default
- Membership of the AllowJobExecution or db_owner role in the repository database.
- The service login as a member of the jobs_admin role in the job database, which is in addition to jobs_reader:
/* In the job database */
ALTER ROLE jobs_admin ADD MEMBER DBADashService;Without the permission the job database refuses the EXECUTE, and the message says so.
Status
Elastic jobs use the same thresholds, exclusions and acknowledgements as SQL Agent jobs. Thresholds can be set at root level (which also applies to SQL Agent jobs), for the job database, or for a job, from the Configure menu on the Elastic Jobs tab. The default root thresholds make a job critical if it failed in the last hour, and a warning if it failed in the last 7 days.
- Timed out and canceled executions count as failures. Skipped executions - a step that didn’t run against a target because its previous execution there was still running - are counted separately, and aren’t failures.
- Target fails are the executions of a job’s steps against their targets that failed, which the job step fail thresholds apply to.
- An exclusion with a category filter doesn’t apply to elastic jobs, as they don’t have categories.
Summary page
The Job column of an Azure server’s row is the status of the elastic jobs on the server. View opens the server’s Elastic Jobs node. The Summary page’s Report view, and daily reports, have an Elastic jobs section listing the jobs with a problem against their Azure server.
Alerts
Add an Elastic Job alert rule to be notified when a job fails. The alert is raised against the job database and lists the databases the execution failed against. It’s resolved when the job next succeeds, or is disabled or deleted. The rule can be filtered by job name, with LIKE syntax.



