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

Azure SQL Database 2014-04-01 API退役后,如何使用推荐弹性池端点?

解决Microsoft.Sql/servers/recommendedElasticPools端点的API版本问题

临时使用即将退役的2014-04-01 API调用端点

虽然该API版本即将被淘汰,但如果当前必须使用Microsoft.Sql/servers/recommendedElasticPools端点,你可以在ARM模板或REST请求中明确指定apiVersion为2014-04-01:

  • ARM模板示例(引用推荐弹性池下的数据库):
{
  "type": "Microsoft.Sql/servers/recommendedElasticPools/databases",
  "apiVersion": "2014-04-01",
  "name": "[concat(variables('serverName'), '/', variables('recommendedPoolName'), '/', variables('dbName'))]",
  "dependsOn": [
    "[resourceId('Microsoft.Sql/servers/recommendedElasticPools', variables('serverName'), variables('recommendedPoolName'))]"
  ]
}
  • 注意:微软会逐步终止该API的支持,务必在退役截止前完成迁移,避免服务中断。

改用当前支持的替代方案

微软目前推荐使用最新API版本结合智能顾问能力来替代旧的推荐弹性池端点,具体方式如下:

  1. 使用Microsoft.Sql/servers/elasticPools(API版本2021-11-01及以上)创建弹性池,示例模板:
{
  "type": "Microsoft.Sql/servers/elasticPools",
  "apiVersion": "2021-11-01",
  "name": "[concat(variables('serverName'), '/', variables('elasticPoolName'))]",
  "location": "[resourceGroup().location]",
  "sku": {
    "name": "GP_Gen5",
    "tier": "GeneralPurpose",
    "capacity": 2
  },
  "properties": {
    "maxSizeBytes": 34359738368,
    "perDatabaseSettings": {
      "maxCapacity": 2,
      "minCapacity": 0.5
    }
  },
  "dependsOn": [
    "[resourceId('Microsoft.Sql/servers', variables('serverName'))]"
  ]
}
  1. 通过Azure Portal的SQL Server Advisor面板,获取针对现有数据库的弹性池最优配置推荐,直接应用到新建弹性池中,这是官方推荐的长期方案。

关键注意事项

  • 密切关注微软发布的API退役时间表,提前规划迁移工作。
  • 如果业务依赖推荐弹性池的自动生成数据,可临时使用2014-04-01 API,但必须同时推进替代方案的落地。

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

相关产品推荐
方舟 Agent Plan

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

最近更新时间:2026.06.23 16:07:38