title: Should one call .close() on HttpServletResponse.getOutputStream()/.getWriter()?
body: <p>In Java Servlets, one can access the response body via <code>response.getOutputStream()</code> or <code>response.getWriter()</code>. Should one call <code>.close()</code> on this <code>OutputStream</code> after it has been written to?</p>
  
  <p>On the one hand, there is the Blochian exhortation to always close <code>OutputStream</code>s. On the other hand, I don't think that in this case there is an underlying resource that needs to be closed. The opening/closing of sockets is managed at the HTTP level, to allow things like persistent connections and such.</p>