Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Conditional and scheduled monitoring

An alert normally runs whenever it is enabled. With conditional monitoring (Trial / Pro) an alert, or a monitor - a Metric Set collected, or a file watched in the background - runs only when it is worth it:

  • on a schedule - business hours, a nightly batch window, a one-off maintenance night;
  • when another alert fires - a service restart starts watching the connection pool’s counters for an hour;
  • when you start it - for an hour, or until you stop it.

The rest of the time it is dormant: nothing is read or collected for it. When the signal comes, TKTail watches more closely, and every incident says why it was watching.

How it fits together

ActivationWhen an alert or a monitor runs: Always (while enabled), On a schedule, or Only when activated
ScheduleWindows in a time zone: recurring (Mon-Fri 07:00-18:00, every day 22:00-06:00) and one-off (2026-11-15 21:00 until 2026-11-16 03:00)
When this alert firesThe alerts and monitors an alert activates when it fires, each for a while (15 min … 24 h) or until stopped
ReasonsA schedule window, each alert that activated it, you - each kept apart. It runs while any reason remains and stops when the last one ends
Resource classLight, Moderate or Heavy - what running it costs. A Heavy one runs only after you approve it
HistoryEvery start, end and refusal - History… in Conditional Monitoring, and activation-history.jsonl in the data folder

A schedule and an activation are not alternatives: an alert that fires can keep a scheduled monitor running after its window ends, and two alerts can keep one target running for overlapping periods - each reason is listed, and the target stops only when none is left.

Setting when an alert runs

In the alert editor (Tools > Manage Alerts… > Edit…, or a new alert) press Activation…:

FieldMeaning
RunsAlways (while enabled) - as before; On a schedule - in its windows (an alert or you can also start it outside them); Only when activated - by an alert that fires, or by you
Time zoneThis computer’s time zone (it moves with the computer), or a named Windows zone such as Central European Standard Time - kept as written, so 07:00 stays 07:00 there when the computer is elsewhere
WindowsAdd Window… - the days a window starts on, From and To (HH:MM); Add One-off… - From and Until as dates and times in the schedule’s zone; Remove
Allow heavy monitoringShown for a Heavy target: your approval (Resource classes)
When this alert firesAdd… - an alert or a monitor to activate, and for how long; Remove

The line under the windows says what the schedule means now - In a window now - until 2026-11-11 18:00, or Not in a window now - the next one starts 2026-11-16 07:00 - from the same evaluation the alerts use.

How windows are read:

  • Overnight: a To time not after From ends the next day - 22:00 to 06:00 is one window, starting on the days you check (a Friday-night window ends on Saturday morning).
  • Several windows are allowed (up to 16). Windows that overlap or touch are one span: 07:00-12:00 and 10:00-14:00 run from 07:00 to 14:00 - started once, never stopped and started again at 10:00 or 12:00. A window entered twice counts once.
  • Daylight saving: a time the clocks skip in spring (02:30 when they jump from 02:00 to 03:00) is the moment of the change; a time that happens twice in autumn is its first occurrence. A recurring rule stays a wall-clock rule: 07:00 is 07:00 local in winter and in summer.
  • One-off windows are entered in the schedule’s zone and kept as fixed times (UTC).
  • A zone this computer does not know is never active - the line says so.

Without a window nothing runs on a schedule; Only when activated needs no window at all.

Activating other alerts and monitors

Under When this alert fires add what the alert activates - another alert, or a monitor - for 15 or 30 minutes, 1, 2, 4, 8 or 24 hours, or until revoked (until you stop it). An alert has at most 8 such actions; an alert never activates itself.

Each incident activates each target once: an alert that fires again within the same incident does not start it again, a new incident starts a new period. Chains are bounded - an alert that activates an alert that activates another works up to three steps; a loop (A activates B, B activates A) or a deeper chain is refused and written to the history, and the incident says not activated … - a cycle. At most 256 activations are active at once.

Activating something never widens what it reads: an activated alert runs exactly its own condition on its own files, a monitor exactly its Metric Set or file.

Conditional monitors

Tools > Conditional Monitoring… lists your monitors - what each watches and what it is doing now (Dormant, Dormant - next window 2026-11-16 07:00:00, Scheduled window Mon-Fri 07:00-18:00 - … - until 2026-11-11 18:00:00, Alert “App restart” (#12) incident … - until 2026-11-11 14:03:00, Started by the user - until 2026-11-11 15:12:00 - local times):

Add… / Edit…Name; A Metric Set collected every 250 ms … 60 s while it is active, or A file watched in the background while it is active (as an alert’s file is); Enabled; Activation… as above (no actions - a monitor fires nothing)
RemoveRemoves it; an alert that activated it then activates nothing in its place. Its history stays
Start for 1 HourStarts it now, for an hour - next to its schedule and any alert that activated it
Stop NowEnds the activations by alerts and by you; its schedule stays (a scheduled monitor in its window keeps running)
History…This session’s activations, refusals and ends

The details under the list also say which alerts activate the selected monitor (Triggered by: alert “API Failure” (#1) - for 30 min) - the same relations Manage Alerts shows; Go to Monitor… in Manage Alerts’ Relationships opens this window at that monitor.

A Metric Set monitor makes its counters collected while it is active, so an incident that keeps that Metric Set as evidence (Alerts and monitoring) has their history. Up to 64 monitors; they are kept in monitors.json in the data folder.

Resource classes

ClassWhatRuns
LightA file; a few counters every 5 s or slowerWhen its activation says
ModerateCounters every 1 to 4 s, or more than 8 of them; a Performance Counter alert (collected every second)When its activation says
HeavyCounters faster than every second, or more than 32 of themOnly after you check Allow heavy monitoring for this one in its Activation

A Heavy target is never started because its window came, because an alert asked for it, or because you started TKTail inside its window - until you approve it, it stays dormant and says so (Dormant - Heavy resource class - not started without the user’s approval), Start for 1 Hour is refused with the reason, and an alert that would activate it gets not activated in its incident. Only you approve it, in TKTail; an AI assistant cannot.

Why is it running?

  • Manage Alerts: the Activation now column (Scheduled Active, Triggered Active, Active - 2 reasons, Inactive, Blocked …) and the Evaluated column (Yes - Scheduled window …, No - Dormant - next window …); the Relationships and runtime tree under the list shows the alert’s base activation, every reason it runs now (a window and the alerts that activated it are kept apart - when the window ends, an activation still running keeps it running), the alerts that can trigger it, what it activates when it fires, and this session’s activations with refusals and their reasons (Managing alerts). Stop Activation ends what alerts and you started (its schedule stays).
  • Alert Events: right-click an event > Show Relationships - the alert’s tree, with that event’s own activation path first.
  • Conditional Monitoring: the Now column and the details, every reason with its end.
  • Incidents: the details and the exported README have an ACTIVATION section - why the alert was running when it fired (Scheduled window Mon-Fri 07:00-18:00 - Central European Standard Time - since …, until …; Alert “App restart” (#12) incident … - since …, until …), and what it activated (activated: monitor “Pool counters” until …, or not activated: … - why). That explains why data exists for one period and not another.

After a restart

An activation for a while ends at its time - also when TKTail was not running then: one started at 14:00 for an hour ends at 15:00 whether TKTail restarted at 14:30 or at 16:00. An activation until revoked continues after a restart until you stop it. Schedules are worked out again from the clock: TKTail started inside a window runs the target at once (a Heavy one only with your approval), started outside it waits for the next window. Kept in the data folder: monitors.json (your monitors), activations.json (the activations that are running), activation-history.jsonl (what happened) - see Data and privacy.

Without a license

Conditional and scheduled monitoring is part of the Trial and Pro editions (Conditional and scheduled monitoring). Without it, alerts that always run work as before; a conditional alert or monitor is kept as you made it and stays dormant - never deleted, never made always-on. Tools > Conditional Monitoring… is marked (Pro) and says why. See License.

When a trial or license ends while something is running:

What was runningWhat happens
An activation with an end (for 1 h, an AI assistant’s monitoring)runs to its end - it was started while the license had it
A schedule windowwaits: no window opens until a license is entered again
An activation until revokedwaits (it has no end of its own); it counts again when a license is entered again
A new activation - an alert firing, Start for 1 Hournot started (Start for 1 Hour says why)

Nothing is deleted: the definitions, schedules, monitors and the activation history stay. Manage Alerts’ relationships say Paused by the license; Conditional Monitoring’s Now says what still runs and until when.

With an AI assistant

An assistant you allowed (AI integration) can read what runs and why - every target’s activation, its reasons with their ends, the next schedule change, the activations and the history (tktail_list_activations) - and with Allow AI to manage alerts propose and save an alert’s schedule or its when this fires actions, with your yes. It cannot start, extend or stop your activations, and cannot approve a Heavy class: those are yours, in TKTail.

Monitoring an assistant starts

An assistant can collect one Metric Set for a limited time - for example a service’s CPU, memory, threads and handles every 5 seconds for 30 minutes - without PowerShell. TKTail runs it as a temporary monitor:

  • it is listed here, in Tools > Conditional Monitoring… (AI: Process Diagnostics: ATSService, its reason Started by an AI client (MCP stdio) - until 14:35; select it and the details say which client started it and when, what it collects, how often and until when), and as a running job in Jobs (Metric monitoring, who started it, the interval and the end); the METRICS panel shows AI client: … as the collector of its metrics;
  • it ends by itself at its time - at most 60 minutes after it started - and with TKTail; Stop here or Cancel in Jobs ends it at once; it cannot be edited and is never saved as one of your monitors;
  • it collects every 5, 10 or 30 seconds, at most 32 metrics, never a Heavy collection, and at most three run at once;
  • it needs the Metrics and Conditional Monitoring parts of the license, as your own monitors do.

Its samples stay in the metric history for the time Keep History keeps (15 minutes by default) - the assistant reads them while it runs.