title: Listening events in a web service or API over Database changes
body: <p>I have this scenario, and I don't really know where to start. Suppose there's a Web service-like app (might be API tho) hosted on a server. That app receives a request to proccess some data (through some method we will call processData(data theData)).</p>
  
  <p>On the other side, there's a robot (might be installed on the same server) that procceses the data. So, The web-service inserts the request on a common Database (both programms have access to it), and it's supposed to wait for that row to change and send the results back.</p>
  
  <p>The robot periodically check the database for new rows, proccesses the data and set some sort of flag to that row, indicating that the data was processed.</p>
  
  <p>So the main problem here is, what should the method proccessData(..) do to check for the changes of the data row?. </p>
  
  <p>I know one way to do it: I can build an iteration block that checks for the row every x secs. But i don't want to do that. What I want to do is to build some sort of event listener, that triggers when the row changes. I know it might involve some asynchronous programming</p>
  
  <p>I might be dreaming, but is that even possible in a web enviroment.?</p>
  
  <p>I've been reading about a SqlDependency class, Async and AWait classes, etc.. </p>