Databricks event reviewer
This incident-review node receives Databricks notifications through an emitter and calls the separate Databricks integration node. Responsibilities are split as follows:
Capabilities
| Capability | Kind | Signature | Module | Summary |
|---|---|---|---|---|
review_databricks_event | traversal | (event: Dict[str, Any] = {}, event_id: str = '', event_type: str = '', payload: Dict[str, Any] = {}, databricks: Dict[str, Any] = {}, trigger: TriggerContext | None = None) -> dict | examples/python/features/databricks_events/agent.py | Review one Databricks notification (server-normalized fields, or a raw payload in ``event``): fetch the run and a metric summary, decide a verdict. |
summarize_metric_change | traversal | (metric_name: str, time_window: str) -> dict | examples/python/features/databricks_events/agent.py | Direct-call example: plan an investigation through the Databricks node; model review only with a configured endpoint. |
Commands
python -m atfgraph.worker --module examples.python.features.databricks_events.agent:app
python -m atfgraph.worker --module integrations.databricks.node.agent:app &
Files
examples/python/features/databricks_events/README.mdexamples/python/features/databricks_events/__init__.pyexamples/python/features/databricks_events/agent.pyexamples/python/features/databricks_events/agentnode.yaml
README
This incident-review node receives Databricks notifications through an emitter and calls the separate Databricks integration node. Responsibilities are split as follows:
- The graph server verifies the webhook and admits work.
- The
databricksnode owns Jobs, SQL and AI Functions calls. incident_reviewercomposes those capabilities and returns a rule-based verdict:incident,watch,no_actionorneeds_review.
The optional summary calls databricks.ai_query only when DATABRICKS_AI_ENDPOINT is configured. Otherwise it reports review_skipped, without inventing a model answer.
Run (fixture mode, no workspace)
Start a daemon with DATABRICKS_WEBHOOK_SECRET in its environment, then run the fixture nodes from the repository root:
DATABRICKS_FIXTURE_DIR=integrations/databricks/fixtures DATABRICKS_WAREHOUSE_ID=wh-fixture \
python -m atfgraph.worker --module integrations.databricks.node.agent:app &
python -m atfgraph.worker --module examples.python.features.databricks_events.agent:app
Find the reviewer's /hooks/{emitter_id} URL in its log and send a job-notification payload:
curl -X POST "$URL" -H "Authorization: Bearer $DATABRICKS_WEBHOOK_SECRET" \
-H 'content-type: application/json' \
--data @integrations/databricks/fixtures/jobs_on_failure.json
For this fixture, inspect verdict: incident, failed task load, the state message and metric rows. The path should show two calls to the Databricks node.
Emitter source
The example defaults DATABRICKS_TRIGGER_SOURCE to generic_bearer, requiring the sender's matching Bearer secret. The reviewer normalizes its raw body. A configured databricks source uses Basic verification, source normalization, run/event deduplication and workspace/job filters. Verify that the source is enabled in your server before selecting it; the default bridge does not demonstrate that provider-specific route.
tests/test_databricks_integration.py uses a real daemon with fixture Databricks services. It does not verify live workspace notifications.