title: How to use SignalR in an Azure function app?
body: <p>I'm building a small game that will be driven by web socket using SignalR on one hand and Azure function app on the other hand. Basically, the user establishes a web socket connection with the server and sends/receives a message from it. This is mainly done this way because players can discuss with each other in real-time.</p>
  
  <p>Besides, I'd like to have some Azure function apps that run and execute some instructions. For example, every minute, an app would make some monsters move. If these monsters are around a specific player, I'd like him to know.</p>
  
  <p>For this, I have two solutions in mind: </p>
  
  <ul>
  <li>Requesting the information every second from the client and then warning the user if he needs to be.</li>
  <li>Opening a connection to my web socket from within my function app to send the data and the hub would forward the information to affected users.</li>
  </ul>
  
  <p>The first option kind of defeat the purpose of a web socket to me. What's the point of having web socket if I need to poll the server for some information.</p>
  
  <p>The second option seems better but as I'm not familiar with function apps yet, I'm wondering if it's the way to go. Is it possible/correct to open a web socket connection from a function app? </p>
  
  <p>Maybe there are some better options?</p>