11.2 Event-Driven Architecture Design (Event Grid, Event Hub)

Key Takeaways

  • Azure Event Grid is for reactive, discrete event notifications pushed to handlers (Functions, Logic Apps, Service Bus, Storage Queues, webhooks); Azure Event Hubs is for high-throughput telemetry streaming ingested by multiple independent readers.
  • Event Grid System Topics let Azure resource providers (Blob Storage, Resource Groups, IoT Hub) emit events automatically with no publishing code required.
  • Event Hubs Consumer Groups give each downstream application (a dashboard, an archiving job, a machine-learning pipeline) its own independent read position on the same stream.
  • Event Hubs Standard tier retains data for up to 7 days; Premium and Dedicated tiers extend retention to up to 90 days and use Processing Units / Capacity Units instead of Throughput Units.
  • Event Hubs Capture automatically and continuously archives the stream to Blob Storage or Data Lake Storage Gen2, giving a durable raw landing zone alongside real-time processing at no extra service cost beyond storage.
Last updated: July 2026

Why Event-Driven Architecture Design Matters on AZ-305

Still inside Design infrastructure solutions (30-35%) and the application-architecture subgroup, this section covers the piece candidates most often confuse with the messaging services from 11.1: event-driven architecture. The key conceptual line is that messaging carries business data that must be reliably processed exactly once (in effect), while eventing carries lightweight, fire-and-forget notifications that something happened, which any number of independent subscribers may react to. AZ-305 frequently presents a scenario and asks you to choose among Event Grid, Event Hubs, and Service Bus — all three plausible-sounding, only one correct for the stated throughput, delivery, and consumer pattern.

Core Concepts and Terminology

Azure Event Grid

Event Grid is a fully managed, reactive publish-subscribe service for discrete event notifications — "a blob was created," "a virtual machine was deleted," "a device reported a state change."

  • Push-based delivery: Event Grid pushes events to event handlers — Azure Functions, Logic Apps, Service Bus, Event Hubs, Storage Queues, generic webhooks, or Hybrid Connections — rather than waiting for a consumer to poll.
  • System Topics: many Azure resource providers automatically emit events with zero publishing code. The most-tested example is a Storage Account's BlobCreated/BlobDeleted events, but Resource Groups, IoT Hub, and others behave the same way.
  • Custom Topics: your own application publishes its own event types when no built-in system topic fits.
  • Schema: events use the Event Grid schema or the interoperable CloudEvents v1.0 schema, which matters when integrating with non-Azure event consumers.
  • Delivery and retry: at-least-once delivery with exponential-backoff retries for up to 24 hours by default, after which an undelivered event is dead-lettered to a Storage blob container if one is configured.
  • Filtering: subject filters (prefix/suffix match) and advanced filters (matching on event-data property values) let each subscription receive only the events it actually cares about from a shared feed.
  • Event Grid Domains: a management construct for publishing at very large scale — thousands of topics exposed under a single ingestion endpoint, useful for SaaS providers emitting per-tenant events.
  • Latency: near-real-time, typically well under a few seconds — this is a notification fabric, not a high-volume analytics pipeline.

Azure Event Hubs

Event Hubs is a big-data streaming ingestion pipeline built for telemetry-scale volume — millions of events per second from devices, applications, or click-streams.

  • Partitioned consumer pattern: the stream is split into partitions, each read independently, enabling parallel consumption at scale.
  • Consumer Groups: each downstream application gets its own independent view of the entire stream, with its own read offset — a live dashboard, a long-term archiving job, and a machine-learning training pipeline can all read the same events at their own pace without interfering with each other.
  • Retention: Standard tier retains events for up to 7 days; Premium and Dedicated tiers extend retention to up to 90 days.
  • Throughput scaling and billing units differ by tier: Standard tier is billed in Throughput Units (TUs), where one TU provides up to 1 MB/second ingress (capped at 1,000 events/second) and up to 2 MB/second egress; Premium tier is billed in Processing Units (PUs), purchasable as 1, 2, 4, 6, 8, 10, 12, or 16; Dedicated tier uses isolated, single-tenant Capacity Units (CUs) for the very largest workloads (zone-redundant Dedicated clusters require the equivalent of 8 CUs).
  • Partition count: fixed at creation time for the Standard tier — plan for your expected number of parallel consumers up front — while Premium and Dedicated allow more dynamic partition management.
  • Event Hubs Capture: automatically and continuously archives the raw stream to Blob Storage or Azure Data Lake Storage Gen2 on a time or size interval, at no cost beyond the storage consumed — a common way to keep a durable raw landing zone running alongside real-time stream processing.
  • Kafka compatibility: Event Hubs exposes a Kafka-compatible endpoint, so existing Apache Kafka producers and consumers can point at Event Hubs by swapping the connection endpoint, with no code rewrite.
ServicePurposeDelivery modelTypical scaleOrderingRetention
Event GridDiscrete reactive notificationsPush (webhook) to handlersLow-to-moderate event rateNot guaranteedNot a store; retry window only
Event HubsHigh-volume telemetry ingestionPull, partitioned, multiple consumer groupsMillions of events/secPer-partition order only7 days (Standard) to 90 days (Premium/Dedicated)
Service BusReliable business messagingPush/pull, queues and topicsModerate, transactionalGuaranteed via SessionsUntil consumed or expired

Decision Framework

  • React to a single discrete resource-state change and fan it out to a handful of handlers → Event Grid (often via a System Topic, no publishing code needed).
  • Ingest continuous, high-volume telemetry or click-stream data that several independent downstream systems must each read at their own pace → Event Hubs with one consumer group per downstream system.
  • Need guaranteed order, transactional completion, or duplicate suppression for business data → Service Bus (11.1), not Event Grid or Event Hubs.

Exam Scenario

A connected-vehicle fleet emits sensor telemetry at roughly two million events per minute. The company needs a live anomaly-detection dashboard, a separate long-term raw archive for compliance, and a machine-learning training pipeline — all reading the same incoming stream independently, without one consumer's slowdown affecting the others. The correct design is Event Hubs with Capture enabled for the archive and one consumer group per downstream application (dashboard, ML pipeline) so each maintains its own offset. Event Grid is wrong here because it is not designed for firehose-scale telemetry throughput or for multiple independent replay-style readers of the same feed.

A second scenario: whenever a new image is uploaded to a Storage Account, the platform must automatically trigger a thumbnail-generation Function and, from that same upload event, notify a separate Logic App that performs content moderation — with no custom infrastructure to manage for the fan-out itself. The correct design is an Event Grid System Topic on the storage account with two event subscriptions, one per handler, each optionally scoped with a subject filter if only certain blob paths matter.

Test Your Knowledge

A SaaS platform needs a live dashboard, a compliance archive, and a fraud-detection model to each independently read the same incoming stream of millions of clickstream events per minute, at their own pace. Which Event Hubs feature makes this possible?

A
B
C
D
Test Your Knowledge

A team wants a new blob upload in a Storage Account to automatically trigger both a thumbnail-generation Function and a separate content-moderation Logic App, with no custom code to publish the event. Which Azure service and feature accomplish this?

A
B
C
D
Test Your Knowledge

An Event Hubs namespace on the Standard tier must retain streamed events for regulatory review 45 days after ingestion. What must the architect do?

A
B
C
D