3
如何处理使用长颈鹿的失败后操作?如何处理使用长颈鹿失败的后期操作?
使用长颈鹿失败后操作的建议做法是什么?
let private registrationHandler =
fun(context: HttpContext) ->
async {
let! data = context.BindJson<RegistrationRequest>()
let response = register data |> function
| Success profile -> profile
| Failure -> ???
return! json response context
}
具体来说,如果服务器无法将数据写入到一些数据库,我应该返回给客户端(这将编译)。