title: Simple HTTP server in Java using only Java SE API
body: <p>Is there a way to create a very basic HTTP server (supporting only GET/POST) in Java using just the Java SE API, without writing code to manually parse HTTP requests and manually format HTTP responses? The Java SE API nicely encapsulates the HTTP client functionality in <code>HttpURLConnection</code>, but is there an analog for HTTP server functionality?</p>
  <p>Just to be clear, the problem I have with a lot of <code>ServerSocket</code> examples I've seen online is that they do their own request parsing/response formatting and error handling, which is tedious, error-prone, and not likely to be comprehensive, and I'm trying to avoid it for those reasons.</p>