I have this code in a method which is uploading a file using POST-method:
HttpClient httpClient = new DefaultHttpClient();
httpClient.getParams().setParameter(CoreProtocolPNames.PROTOCOL_VERSION, HttpVersion.HTTP_1_1);
and then some other non-deprecated logic (will provide if needed, can't copy and paste). I've read some of the posts and am trying to use CloseableHttpClient, but I can't come up with an idea how to update the code. I've just started working on this project and am really inexperienced with it.
This method uploads a file and receives a response from the server. My question is - how do I write the same code without using deprecated methods?