I followed the tutorial Visual Studio Code quickstart and created a durable function locally. I got an error message when my durable function executed await client.startNew inside the starter function
const instanceId = await client.startNew(req.params.functionName, undefined, req.body);
Here is the error messages:
Executed 'Functions.HttpTrigger' (Failed, Id=84dc103d-bef9-4450-b4c6-9e612c6dc263) System.Private.CoreLib: Exception while executing function: Functions.HttpTrigger. System.Private.CoreLib: Result: Failure Exception: Error: write EPROTO 101057795:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:openssl\ssl\s23_clnt.c:827: Stack: Error: write EPROTO 101057795:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:openssl\ssl\s23_clnt.c:827: at _errnoException (util.js:992:11) at WriteWrap.afterWrite [as oncomplete] (net.js:864:14).
My environment:
- Azure Functions Core Tools (2.3.148)
- Function Runtime Version(2.0.12210.0)
- Node.js 8
Here is my code just copied from the tutorial.
const df = require("durable-functions");
module.exports = async function (context, req) {
const client = df.getClient(context);
const instanceId = await client.startNew(req.params.functionName, undefined, req.body);
context.log(`Started orchestration with ID = '${instanceId}'.`);
return client.createCheckStatusResponse(context.bindingData.req, instanceId);
};
{
"bindings": [
{
"authLevel": "anonymous",
"name": "req",
"type": "httpTrigger",
"direction": "in",
"route": "orchestrators/{functionName}",
"methods": ["post"]
},
{
"name": "$return",
"type": "http",
"direction": "out"
},
{
"name": "starter",
"type": "orchestrationClient",
"direction": "in"
}
]
}
How do I resolve this problem?