title: How to print all the request headers which HttpURLConnection is sending?
body: <p>I am using HttpURLConnection in one of my Java program to hit a HTTP URL via Java.</p>
  
  <p>I know I can set the request header value something like this.</p>
  
  <p>connObj.setRequestProperty("User-Agent", "curl/7.29");</p>
  
  <p>But I want to print all the request headers which is generated by URLConnection. Is that possible?</p>