我有一个应用程序的服务计划,它可以扩展以下面的方式:天青自动缩放古怪行为
- 范围:2-20实例
- CPU> 20%:分至20个实例
- CPU < 15%:规模至2个
,我看到随着时间的推移实例的实际数量如下:
-
个
- 20个实例
- (CPU〜0%)
- 规模下降到2个实例
- (负载开始:CPU> 50%)
- 高达20个实例(在〜5分钟)
- (负载完成:CPU〜0%)
- 到15个实例(在〜5分钟)
- 至12个实例(在〜5分钟)
- 降至5个实例(在〜5分钟)
- 下降至2个(中〜5分钟)
如何使它扩展至2个瞬间,没有之间,额外的步骤?
此外,有时,从2到20个实例的规模上升失败,并且2个实例保持在巨大负载下。是否有可能告诉Azure尽可能扩展到更多的实例,而不是在巨大的负载下将2个实例留给用户?
更新:添加比例设置JSON。
更新:添加比例设置截图。
{
"id": "...",
"name": "...",
"type": "Microsoft.Insights/autoscaleSettings",
"location": "westus",
"tags": {
"$type": "...",
"...": "Resource"
},
"properties": {
"profiles": [
{
"name": "Default",
"capacity": {
"minimum": "2",
"maximum": "20",
"default": "2"
},
"rules": [
{
"metricTrigger": {
"metricName": "CpuPercentage",
"metricNamespace": "",
"metricResourceUri": "...",
"timeGrain": "PT1M",
"statistic": "Average",
"timeWindow": "PT5M",
"timeAggregation": "Maximum",
"operator": "GreaterThan",
"threshold": 20
},
"scaleAction": {
"direction": "Increase",
"type": "ExactCount",
"value": "20",
"cooldown": "PT1M"
}
},
{
"metricTrigger": {
"metricName": "CpuPercentage",
"metricNamespace": "",
"metricResourceUri": "...",
"timeGrain": "PT1M",
"statistic": "Average",
"timeWindow": "PT5M",
"timeAggregation": "Average",
"operator": "LessThan",
"threshold": 15
},
"scaleAction": {
"direction": "Decrease",
"type": "ExactCount",
"value": "2",
"cooldown": "PT1M"
}
}
]
}
],
"enabled": true,
"name": "...",
"targetResourceUri": "...",
"notifications": [
{
"operation": "Scale",
"email": {
"sendToSubscriptionAdministrator": false,
"sendToSubscriptionCoAdministrators": false,
"customEmails": [
"..."
]
},
"webhooks": null
}
]
}
谢谢,我已经阅读过此材料。 问题实际上是关于 - 为什么Azure会根据配置进行缩放。在配置中,它可以是2个实例或20个。实际上 - 显示其他数字。 –
这可能是多个政策和规则的冲突问题。 –
那么,我必须规则:一个设置为20个实例,另一个设置为2个实例。没有规则可以添加/删除N个实例,只有这两个规则。我不明白他们怎么会发生冲突,以至于我得到15个例子。 –