title: What is the preferred way to specify an HTTP "Location" Response Header in Spring MVC 3?
body: <p>What is the preferred way to specify an HTTP "Location" Response Header in Spring MVC 3?</p>
  
  <p>As far as I can tell, Spring will only provide a "Location" in response to a redirect ("redirect:xyz" or RedirectView), however there are scenarios where a Location should be sent along with the entity body (ex, as a result of a "201 Created").</p>
  
  <p>I'm afraid my only option is manually specifying it:</p>
  
  <pre><code>httpServletResponse.setHeader("Location", "/x/y/z");
  </code></pre>
  
  <p>Is this correct?  Is there a better way to tackle this problem?</p>