This repository was archived by the owner on Dec 9, 2024. It is now read-only.
This repository was archived by the owner on Dec 9, 2024. It is now read-only.
eventHub trigger not working on azure portal #361
Open
Description
This is a Bug Report
Description
- What went wrong?
I successfully deploy my serverless functions to Azure, setting eventHub as binding.
While I visit the function page on azure an error appears and the function does not work:
Error: Microsoft.Azure.WebJobs.Host: Error indexing method 'Functions.myfunc'. Microsoft.Azure.WebJobs.EventHubs: Value cannot be null. Parameter name: receiverConnectionString.
- What did you expect should have happened?
The function to work correctly - What was the config you used?
serverless.yml
myfunc:
handler: src/entrypoint.myfunc
events:
- eventHub:
x-azure-settings:
name: items # Specifies which name it's available on `context`
eventHubName: myfunc-events # Specifies the Name of the Event Hub
consumerGroup: myfuncchannel # Specifies the consumerGroup to listen with
connection: ${opt:eh} # App Setting/environment variable which contains Event Hubs Namespace Connection String
- What stacktrace or error message from your provider did you see?
function.json
{
"disabled": false,
"bindings": [
{
"type": "eventHubTrigger",
"direction": "in",
"name": "items",
"eventHubName": "myfunc-events",
"consumerGroup": "myfuncchannel",
"connection": "Endpoint={myurl}"
}
],
"entryPoint": "myfunc",
"scriptFile": "../src/entrypoint.js"
}
error
Error: Microsoft.Azure.WebJobs.Host: Error indexing method 'Functions.myfunc'. Microsoft.Azure.WebJobs.EventHubs: Value cannot be null. Parameter name: receiverConnectionString.
Similar or dependent issues:
Additional Data
- Serverless Framework Version you're using: 1.54.0
- Serverless CLI Version you're using: 1.2.3
- Serverless Azure Plugin Version you're using: 1.0.2
- Operating System: darwin