Q:

Whats the connection in a ServiceBusTrigger?

What is the connection that needs to be defined with my service bus trigger (topic) for my Azure Function?
The Run looks like this
public static void Run([ServiceBusTrigger("testtopic", "testsubscription", AccessRights.Manage, Connection = "")]string mySbMsg, TraceWriter log)

Is it the connection string for the Policy under Shared access policy of the ServiceBus (Endpoint:sb://...)?

A:

Connection is the name of a variable which contains connection string to a bus. You need to keep this variable in Application Settings of your Function App (accessible through the portal) and locally in local.settings.json -  {"Connection" : "Endpoint..."}

