【发布时间】:2021-02-27 07:29:19
【问题描述】:
我有一个http触发功能,当我向url发送消息时,它会根据需要将数据记录在queuestorage上;
http://localhost:7071/api/xxxx?message=89000
但是,当我在 azure 中对函数 url 执行相同操作时
https://yyyyy.azurewebsites.net/api/xxxx?message=89000 没有任何记录。
我该如何解决这个问题?
另一个问题; 底层代码是
import logging
import azure.functions as func
def main(req: func.HttpRequest,msg: func.Out[str]) -> func.HttpResponse:
logging.info('Python HTTP trigger function processed a request.')
input_msg = req.params.get('message')
logging.info(input_msg)
msg.set(input_msg)
return func.HttpResponse(
"This is a test.",
status_code=200
)
预计会收到如下payload
{
"layerId":0,
"serviceName": "myService",
"changeType": "FeaturesCreated",
"orgId": "myorgId"
"changesUrl": "https://olserver/services/myService/FeatureService/extractChanges?serverGens=[1122, 1124]"
}
当我执行http://localhost:7071/api/xxxx?message=89000 时,它会很好地记录队列存储,但不会在传递此有效负载时记录。我该如何配置?
【问题讨论】:
-
还有什么问题吗?如果没有,也许我们可以结束这个问题?
标签: azure-function-app azure-http-trigger