-
Notifications
You must be signed in to change notification settings - Fork 4.1k
How to set the http request port to another value? #79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Would this cause for headers not being sent properly? also using node |
I also have same problem. I want to change the port to 8080. Is there any issue I should keep mind when changing the port? Regarding to change the port, I think, it should be easy to adjust the code accordingly? Hence, changing the constructor of AsyncHttpClient should do the trick or? Something like: public AsyncHttpClient() {
this(80);
}
/**
* Creates a new AsyncHttpClient.
*/
public AsyncHttpClient(int httpPort) {
....
schemeRegistry.register(new Scheme("http", PlainSocketFactory.getSocketFactory(), httpPort));
....
} I haven't tested the code yet. |
Good point, I've committed option to change HTTP and HTTPS ports via constructor. |
# By mareksebera (51) and Marek Sebera (2) # Via mareksebera * 'master' of https://github.com/loopj/android-async-http: (53 commits) Handy method to specify charset in anonymous inner instances Sample Application initial state Removed unnecessary dependency, android-async-http#168 Javadoc formatting Fixed 2d34e1c leftover, Closes android-async-http#86 Fixing android-async-http#79, Allowing non-standard HTTP and HTTPS ports Added warning about SSL bypass fix Related to android-async-http#67, avoiding NPE in JsonHttpResponseHandler Fixes android-async-http#61, allow removing of Basic Auth credentials Compatibility changes fix Fixes android-async-http#14 Fixes android-async-http#143 android-async-http#88 uncatched exception Closes android-async-http#266 Closes android-async-http#283 Fixes android-async-http#286 Fixes android-async-http#294 Fixes android-async-http#287 Fixes android-async-http#295 Added Maven description to README file [skip ci] ... Conflicts: .classpath build.gradle project.properties
I'd like to configure the port to another value.
I want to set the port to 3000, but I noticed that this value 80 is hardcoded.
The text was updated successfully, but these errors were encountered: