⛏️GetSplunky!
Lv.1Intern
0 XP
0
Home Map Stats Drill Board Log In
CoursesArticlesSPL Cheat SheetCertification PathAboutPrivacyTerms

Splunky is an independent, free study resource. It is not affiliated with, endorsed by, or sponsored by Splunk or Cisco. Splunk, SPL and related marks are trademarks of Splunk, a Cisco company, and are used here only to identify the certifications this site helps you study for.

© 2026 Splunky

Back to Floor
SignalFlow Forge • Room 1

Streaming Metrics with data(), filter() & .publish()

SignalFlow is the Python-like streaming analytics language behind every chart and detector in Splunk Observability Cloud.

Every SignalFlow program starts by selecting a metric stream with data(metric_name, filter=...), optionally narrows the stream by dimensions, custom properties, or tags using filter() combined with and, or, or not, and outputs the resulting stream with .publish(label=...). Without .publish(), a SignalFlow stream is computed internally (for intermediate variables) but never plotted on a chart or evaluated by a detector.

Even when you build a chart using the Splunk Infrastructure Monitoring Plot Builder UI, Splunk translates your clicks into SignalFlow under the hood—you can switch to the SignalFlow editor at any time to inspect or customize the exact code.

Basic SignalFlow Program
prod_filter = filter('env', 'prod') and not filter('host.name', 'test-*')
stream = data('cpu.utilization', filter=prod_filter)
stream.mean(by=['service.name']).publish(label='Avg Prod CPU')
Filter as early as possible inside data(..., filter=...) rather than filtering after aggregation so Splunk processes only the relevant Metric Time Series.

Knowledge Check

Prove your understanding to clear the room (Rewards XP)
Complete the SignalFlow program to ingest memory.utilization for env="production", calculate the average across hosts, and output it to a chart:
prod = filter('env', 'production')
('memory.utilization', filter=prod).mean(='host.name').(label='Prod Mem')