title: Offset in Azure EventHubTrigger Function App
body: <p><strong>Expectation:</strong>
  Using a function app with EventHubTrigger-CSharp template runs when a new event is comming in.</p>
  <p><strong>Implementation:</strong>
  Using the very basic example from <a href="https://azure.microsoft.com/en-us/documentation/articles/functions-bindings-event-hubs/" rel="nofollow noreferrer">https://azure.microsoft.com/en-us/documentation/articles/functions-bindings-event-hubs/</a></p>
  <p><strong>Result:</strong>
  The explained method:</p>
  <pre><code>public static void Run(string myEventHubMessage, TraceWriter log)
  {
      log.Info($&quot;C# Event Hub trigger function processed a message: {myEventHubMessage}&quot;);
  }
  </code></pre>
  <p>does deliver the 'first' in the event queue instead of the current one.</p>
  <p><strong>Additional:</strong></p>
  <ul>
  <li>I added a consumerGroup (so not reading from $Default)</li>
  <li>According to this blog: <a href="http://www.yourcloudbuddy.com/2016/04/azure-functions-and-event-hubs.html" rel="nofollow noreferrer">http://www.yourcloudbuddy.com/2016/04/azure-functions-and-event-hubs.html</a> 'there is currently no way to configure it to start a particular offset'.</li>
  </ul>
  <p><strong>Question:</strong>
  How can I receive the newest event on a hub in my function app?</p>
  <p><strong>More info:</strong>
  I need to forward new signals from event hub to an external mqtt api (that works so far). Probably I need another approach?</p>