You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Azure Functions已设10分钟超时,仍5分钟超时问题求助

Troubleshooting Azure Functions 10-Minute Timeout Not Taking Effect

Let's break down why your 10-minute timeout setting isn't working, even though you've adjusted it in the portal and tried setting it in host.json. This is a common issue with a few easy-to-miss fixes:

1. Your host.json has an incorrect structure

Looking at your provided config, you've placed the functionTimeout property inside the queues node—this is wrong! The functionTimeout needs to be at the root level of the host.json file, not nested under queue settings.

Here's the corrected structure you should use:

{
  "version": "2.0",
  "functionTimeout": "00:10:00",
  "queues": {
    "maxPollingInterval": 2000,
    "visibilityTimeout": "00:00:30",
    "batchSize": 16,
    "maxDequeueCount": 3,
    "newBatchThreshold": 8
  }
}

2. Local host.json isn't being deployed correctly

If you're deploying from Visual Studio, make sure your host.json is set to copy to the output directory so it gets included in the deployment package:

  • Right-click the host.json file in your Visual Studio project
  • Select Properties
  • Set Copy to Output Directory to Copy if newer or Copy always
  • Re-deploy your function app to Azure—this will overwrite any manual portal settings with the correct host.json config

3. Verify the portal setting is actually active

Sometimes manual portal edits can get overwritten during deployment, or you might be checking the wrong section. To confirm the active timeout:

  • Go to your Function App in the Azure Portal
  • Navigate to Configuration > Function runtime settings
  • Check the Function timeout value here—it should show 00:10:00 if your config is applied correctly

4. Confirm your function plan and runtime version

  • Consumption Plan: Ensure you're using Azure Functions Runtime v3 or later (the 10-minute timeout limit applies to these versions for Consumption plans)
  • Dedicated/Elastic Plans: These support longer timeouts, but if you're on Consumption, double-check the runtime version in the portal's Overview tab under "Runtime version"

After fixing the host.json structure and re-deploying, test your long-running task again—this should resolve the 5-minute timeout issue.

内容的提问来源于stack exchange,提问作者erincerol

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.28 09:27:57