Azure Functions as Scalable Agent MCP Tools: Architecture and Model-Based Evaluation of Elastic, Serverless Tool Invocation for AI Agents
Agentic AI systems call tools through the Model Context Protocol (MCP), producing bursty, latency-critical traffic that serverless platforms must absorb.This paper presents a reference architecture and a Java 21 implementation pattern for hosting MCP tools on Azure Functions, and evaluates the Consumption, Flex Consumption and Premium hosting plans using a discrete-event simulation with a Markov-modulated workload and an analytical monthly cost model.Under the stated assumptions, Flex Consumption with a small alwaysready floor reached a P99 latency of about 1.1 s at roughly 8 USD per million calls, while a Premium EP2 plan reached about 1.3 s at about 89 USD per million calls; the legacy Consumption plan had a P99 of 4.7 s.Instance-allocation rate and per-instance concurrency, rather than the plan label, dominated tail latency and cost respectively, and per-call tail latency compounds to a 13-18% chance of a slow call in a 10step agent workflow.The results are model-based, not measurements of a live deployment; they are accompanied by sensitivity and break-even analyses and by security and observability guidance.
Authors
- Roshan Kumar Choudhary
Publication Details
- Journal
- International Journal of Computer Applications
- Published
- 2026-11-24
- DOI
- https://doi.org/10.5120/ijcaf628698ff2b2
- Primary Topic
- Cloud Computing and Resource Management
- Type
- article
- Field-Weighted Citation Impact
- 0.00