Schedulers
SQL Server Agent
Job steps are rows in msdb, not files in git. Reads sysjobs, sysjobsteps and sysjobhistory.
A SQL Agent job is not a file. It is a set of rows in msdb, created
through a dialog box, and in most estates there is no copy of it anywhere else. The step
commands — frequently the actual ETL logic — live in
msdb.dbo.sysjobsteps.command.
This makes SQL Agent the clearest illustration of why a repository parser cannot be the source of truth. There is nothing to parse. The definition that runs your nightly load exists in exactly one place, and it is a table.
What Decim reads from SQL Server Agent
Every item below is read-only, and each is a specific view, endpoint or file rather than a category of access. If something here is unacceptable in your environment, it can be removed from the query catalogue — see the agent for how that works.
| What | From | Why it matters |
|---|---|---|
| Job definitions | msdb.dbo.sysjobs | Name, owner, enabled state, description |
| Step commands | msdb.dbo.sysjobsteps | The actual command text — often the ETL itself |
| Run history | msdb.dbo.sysjobhistory | Outcome, duration and message per step per run |
| Live activity | msdb.dbo.sysjobactivity | What is executing now, and what last ran |
| Schedules | msdb.dbo.sysschedules | Frequency, interval and start time |
| Step flow | sysjobsteps.on_success_action | Branching between steps — control edges |
| Proxies | msdb.dbo.sysproxies | Which credential a step runs under |
Permissions required
Written out in full, because "read-only access" is not a specification. Nothing below grants the ability to write, and row access is requested only on the specific tables you name.
USE msdb;
CREATE USER decim_agent FOR LOGIN decim_agent;
GRANT SELECT ON dbo.sysjobs TO decim_agent;
GRANT SELECT ON dbo.sysjobsteps TO decim_agent;
GRANT SELECT ON dbo.sysjobhistory TO decim_agent;
GRANT SELECT ON dbo.sysjobactivity TO decim_agent;
GRANT SELECT ON dbo.sysschedules TO decim_agent;
GRANT SELECT ON dbo.sysjobschedules TO decim_agent;
-- SQLAgentReaderRole is the alternative and grants more than the above.
-- Prefer explicit table grants; role membership is harder to audit. What it builds
What this source contributes to the pipeline topology and to the evidence available during an investigation:
- Control edges between steps, including failure branches
- Transform nodes from step command text
- Schedules, which is how a stall with a clock gets explained
- Run outcomes and durations for anomaly detection
Nodes learned from a definition are marked declared; nodes observed running are marked observed; nodes both declared and observed are verified. Where two sources disagree, the disagreement is recorded as a drift note rather than resolved silently.
Failure modes it surfaces
What this source is uniquely good at proving — and, just as usefully, at disproving. An investigation that can refute a hypothesis cheaply is worth as much as one that confirms it.
| Failure mode | The signal |
|---|---|
| Job silently disabled | sysjobs.enabled = 0 with no failure anywhere |
| Step succeeded doing nothing | Duration far below the step's own history |
| Job overlapped itself | Two run instances with overlapping windows |
| Step failure swallowed | on_fail_action set to continue to the next step |
Limits
What this integration cannot tell you. Stated because an investigation that overstates its sources produces confident wrong answers, which is worse than an honest blocked.
sysjobhistoryis trimmed by agent history limits — often 1,000 rows total, which on a busy instance is days rather than months- A job deleted and recreated loses all prior history and gets a new
job_id - Step output files written to disk are not in
msdband need filesystem access to read
Related integrations
- SQL Server — Reads catalog metadata, procedure bodies and write activity — the definitions git never sees.
- SSIS — SSISDB holds executions, per-component row counts and the parameter values actually used.
- cron & systemd timers — The scheduler with no database. Reads crontabs, timer units and journal history.
See all integrations, or how the sources are combined into one graph.
Get started
Investigating a SQL Server Agent pipeline?
Bring an incident you already know the answer to. If Decim gets it wrong, that is a more useful demo than one where it doesn't.