【发布时间】:2019-08-13 19:21:02
【问题描述】:
在我的 Azure API 管理策略中,我正在检查一些标头并根据找到的内容执行某些操作。
当没有任何条件匹配时(即在otherwise 块中),我如何抛出错误
<policies>
<inbound>
<choose>
<when condition="">
</when>
<when condition="">
</when>
<otherwise>
</otherwise>
</choose>
<base/>
</inbound>
<backend>
<base/>
</backend>
<outbound>
<base/>
</outbound>
<on-error>
<base/>
</on-error>
</policies>
我可能想返回 401,因为我正在检查标题中的组。
【问题讨论】: