验证 Azure Functions CRUD 操作
Validating Azure Functions CRUD operations
我刚刚开始研究 Azure Functions,目前我最关心的问题之一是验证。
到目前为止,我只真正了解了 CRUD 操作,但似乎没有一种方法可以轻松验证来自请求或存储的数据。
我找到了这个 poco-validation 并且认为它可能有用。
我知道这是一个开放式问题,但我很想看看其他人在做什么来验证。
我们最近添加了 Function Filters to the underlying WebJobs SDK but that feature isn't fully exposed yet in Azure Functions (see issue here). Related to this, we're also considering support for validation annotations to be applied to your POCO types (issue here)。
在解决上述问题之前,我们意识到验证的故事并不好。推荐的方法是在调用共享验证的函数代码中执行必需的验证 helpers/code。
我刚刚开始研究 Azure Functions,目前我最关心的问题之一是验证。
到目前为止,我只真正了解了 CRUD 操作,但似乎没有一种方法可以轻松验证来自请求或存储的数据。
我找到了这个 poco-validation 并且认为它可能有用。
我知道这是一个开放式问题,但我很想看看其他人在做什么来验证。
我们最近添加了 Function Filters to the underlying WebJobs SDK but that feature isn't fully exposed yet in Azure Functions (see issue here). Related to this, we're also considering support for validation annotations to be applied to your POCO types (issue here)。
在解决上述问题之前,我们意识到验证的故事并不好。推荐的方法是在调用共享验证的函数代码中执行必需的验证 helpers/code。