Build Stream Analytics job configs with IoT Hub/Event Hub inputs, SQL-like queries, tumbling windows, and multi-output routing.
Build Stream Analytics job configs with IoT Hub/Event Hub inputs, SQL-like queries, tumbling windows, reference data joins, and multi-output routing.
Required Fields
jobNameresourceGroupstreamingUnitsinputsoutputsqueryOutput will appear here...Build an Azure Stream Analytics job with a Stream input (IoT Hub), a Reference input (slowly-changing lookup data from Blob Storage refreshed on refreshInterval), and multiple named outputs, joined and aggregated via a SQL-like query using TumblingWindow for non-overlapping time-based aggregation. eventsOutOfOrderPolicy set to Adjust (versus Drop) combined with eventsOutOfOrderMaxDelayInSeconds and eventsLateArrivalMaxDelayInSeconds together define the job's tolerance for real-world network jitter and device clock skew, a policy and delay window too tight silently drops legitimately late-but-valid telemetry (common with IoT devices on unreliable connections), while a window too generous delays the job's aggregation output waiting for stragglers that may never actually arrive.
It's dropped from window-based aggregation entirely, arriving too late to be included in the tumbling window it logically belongs to, this is a real, silent data-loss risk for IoT scenarios with unreliable device connectivity, if devices are known to occasionally have significant network delay, this window needs to be sized generously enough to accommodate that reality, or a meaningful fraction of legitimate telemetry silently never makes it into aggregated outputs.
It refreshes automatically based on the configured refreshInterval (PT1H in the example), Stream Analytics periodically re-reads the reference data blob according to that interval without requiring a job restart, new or updated device metadata becomes available to the join logic on the next refresh cycle, not instantly, but without manual intervention.
Yes, this is a core and commonly-used capability, a single query script can contain multiple SELECT...INTO statements, each targeting a different named output, all reading from the same underlying input stream(s), as the example demonstrates with alerts, aggregation, and archival all derived from the same joined telemetry-plus-metadata stream in one job.
The builder validates that jobName, resourceGroup, streamingUnits, inputs, outputs, and query all resolve before accepting the JSON as a valid Stream Analytics job definition, the fields the service needs to know the job's compute sizing, data sources, destinations, and processing logic; it can't validate the SQL-like query's syntax or that its INTO clauses correctly reference every declared output, those are only confirmed when the job is actually started against live inputs.
Size eventsLateArrivalMaxDelayInSeconds against your actual device fleet's real-world network reliability, not an optimistic default, a window too tight for genuinely lossy field IoT connectivity silently and permanently drops legitimate telemetry from window aggregations.
Reference data refresh isn't instantaneous, if device metadata changes need to propagate faster than the configured refreshInterval, tighten the interval, but weigh that against the added storage read cost of more frequent refreshes.
Take advantage of multi-output routing from one job when several downstream needs (alerting, aggregation, archival) all derive from the same source stream, consolidating into one job avoids the cost and complexity of multiple jobs each independently re-reading and re-processing the same input.
Was this tool helpful?
Disclaimer: This tool runs entirely in your browser. No data is sent to our servers. Always verify outputs before using them in production. AWS, Azure, and GCP are trademarks of their respective owners.