title: Azure Functions: how to efficiently send batch of messages to Service Bus using bindings?
body: <p>I'm working with Azure Functions 2.0 and trying to send a collection of messages to Azure Service Bus Topic. Currently I'm using <code>IAsyncCollector&lt;T&gt;</code> as output binding :</p>
  
  <pre><code>[FunctionName("MyFunction")]
  public static async Task MyFunction([ServiceBus(MyTopicName, EntityType.Topic, Connection = ServiceBusConnection) outTopic])
  {
      var messages = await GetMessages();
      foreach(var message in messages)
      {
          await outTopic.AddAsync(message);
      }
  }
  </code></pre>
  
  <p>Such approach is pretty convenient (declarative code, no boilterplate) but brings one significant issue: for large number of messages the performance is unacceptable. Is there any other recommended way to work with large batches that need to be sent to Azure Service Bus ?</p>