title: RabbitMQ, RPC, and Correlation ID Matching
body: <p>I'm following one of the RabbitMQ RPC tutorials (<a href="https://www.rabbitmq.com/tutorials/tutorial-six-dotnet.html" rel="nofollow noreferrer">https://www.rabbitmq.com/tutorials/tutorial-six-dotnet.html</a>) and got a little confused around Correlation ID matching.</p>
  
  <p>The tutorial states:</p>
  
  <blockquote>
    <p>That's when the CorrelationId property is used. We're going to set it to a unique value for every request. Later, when we receive a message in the callback queue we'll look at this property, and based on that we'll be able to match a response with a request. If we see an unknown CorrelationId value, we may safely discard the message - it doesn't belong to our requests.</p>
  </blockquote>
  
  <p>But why is it "safe" to discard the message after we've already consumed it from the queue? What about the client that is expecting that message? Shouldn't the message be re-queued to prevent loss?</p>