I have a project which post the rest request and read back the response. with http the function is working fine. But when I use https, I am getting connection refused error. gradle is the build tool here and I added gradle.properties under projectdir, but still I am getting connection refused error.
HttpPost post = new HttpPost(RequestURL);
StringEntity input = new StringEntity(Payload);
post.setEntity(input);
HttpResponse response = client.execute(post);`
gradle.properties add under Project>gradle.properties
systemProp.https.proxyHost=www.somehost.org
systemProp.https.proxyPort=8080
systemProp.https.proxyUser=userid
systemProp.https.proxyPassword=password
When I added gradle.properties for the first time, it was working, but suddenly started throwing this connection refused error.