Back to Blog & resources
Podcast

/AI Agents: Keeping systems (and costs) in check

Can your AI agents survive production AND your budget? In this episode, Yaron Schneider, CTO and co-founder of Diagrid and creator of the foundational open-source tools Dapr and KEDA, unpacks what it takes to build AI agents that are durable, cost-aware and enterprise-ready.

Dapr was created to shift attention away from DevOps tooling and toward developer-focused APIs. Instead of managing infrastructure primitives directly, developers can interact with higher-level abstractions that Dapr provides. This allows teams to swap technologies—such as replacing Kafka—without rewriting large parts of the codebase. The emphasis is on portability and decoupling between business logic and infrastructure.

Architectural Outlook: Microservices and Event-Driven Design

Yaron argues that the industry has often treated microservices as a challenge to conquer rather than an architectural option. Overly fragmented systems, such as thousands of Lambda functions, can lead to operational complexity and latency issues. Monoliths remain valid for certain workloads, and even large cloud providers use them internally.

Technical guidance from the discussion:

  • Avoid “microservice gamification”; right-size services based on workload.
  • Event-driven architectures improve scalability and resource utilization.
  • Use asynchronous workflows where responses do not need to be immediate.
  • Reserve synchronous HTTP calls for cases where real-time feedback is essential.

Agents and AI-Native Systems

A significant portion of the conversation explores the distinction between true autonomous agents and traditional function calls mislabeled as such. Yaron suggests that real agents must be capable of runtime reasoning, dynamic workflows, and durable execution.

Infrastructure needs for agent-based systems:

  • Durable state and "resumability" (continuation-style execution)
  • Identity and authentication controls
  • Access to Pub/Sub, queues, and discovery mechanisms
  • Saga-style workflow orchestration for non-deterministic logic

Dapr Agents extend Dapr with reliability features specifically designed for AI agents, allowing them to resume work even after failures—an essential requirement for production use.

Supported patterns and recommendations:

  • Outbox pattern — endorsed and supported natively in Dapr
  • Event-driven first — switch from HTTP where applicable
  • No YAML for developers — configuration should be code-based
  • Serverless — useful only for lightweight or spike workloads

Cautions:

  • High Lambda/Function counts lead to cost and latency problems
  • Deterministic workflows do not fit AI-driven systems
  • “Agent” should imply autonomy, not function invocation

Yaron predicts a shift from cloud-native systems to AI-native infrastructure, where tools and even code are generated automatically in real time based on objectives. This shift will require robust observability, identity boundaries, and reliability patterns that extend beyond traditional microservice models. He expects the CNCF ecosystem to evolve in this direction as agents take on larger parts of operational workflows.