I\'m using HttpClient latest version (4.x). And right now I\'m trying to do A GET Request. I just posting a Get request.
This is my Code;
public clas
Before httpclient
4.3, this answer in the same page is cool.
But since httpclient
4.3, API seems changed a lot, following code would work:
RequestConfig customizedRequestConfig = RequestConfig.custom().setCookieSpec(CookieSpecs.BROWSER_COMPATIBILITY).build();
HttpClientBuilder customizedClientBuilder = HttpClients.custom().setDefaultRequestConfig(customizedRequestConfig);
CloseableHttpClient client = customizedClientBuilder.build(); // customized client,