Skip to content
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

XMLHttpRequest behind Proxy (in jaggery) #171

Open
dkgkim opened this issue Apr 24, 2017 · 6 comments
Open

XMLHttpRequest behind Proxy (in jaggery) #171

dkgkim opened this issue Apr 24, 2017 · 6 comments

Comments

@dkgkim
Copy link

dkgkim commented Apr 24, 2017

When I set up a proxy using Java command line args and then started the business process server, I found that the login to bpmn-explorer failed.
As you can see, when calling api with XMLHttpRequest, the java options http.proxyHost and http.proxyPort apply well, but the http.nonProxyHosts option does not apply.
.

@manuranga
Copy link
Contributor

Hi Kim,
What is the BPS version you are using?

@dkgkim
Copy link
Author

dkgkim commented Apr 26, 2017

Hi,
I'm using BPS version 3.6.0. And recently I used BPS included in EI 6.1.0.
These modules use Jaggery 0.12.6 and 0.12.8 versions, respectively.

  • org.jaggeryjs.hostobjects.xhr_0.12.6.jar (in BPS 3.6.0)
  • org.jaggeryjs.hostobjects.xhr_0.12.8.jar (in EI 6.1.0)

@manuranga
Copy link
Contributor

Hi Kim,
We are calling localhost form the bpmn-explorer backend (localhost), as you say, this will go through the proxy, and it's an issue. We can't fix this simply, because the apache http-client version we use (3.1.0) doesn't support ignore proxy setting.

I have created an issue in EI project wso2/product-ei#546 and we will consider it for the next EI release.

Until then, can you please try adding etc/hosts entry to the proxy machine to point back at BPS to solve the issue?

@dkgkim
Copy link
Author

dkgkim commented Apr 27, 2017

Hi,
It can be fix by pull request #172.
I coded that ignore proxy setting if target url is included in nonProxyHosts.
Is that way has any problem?

@dkgkim
Copy link
Author

dkgkim commented May 2, 2017

please review the pull request #172 and merge or comment about it.

@manuranga
Copy link
Contributor

Hi Kim,
I didn't notice that we create a HttpClient for each XMLHttpRequest (which is wrong). But that make it possible to fix this at per XMLHttpRequest level as you have done. Thank you very much for sending the PR, I will test with EI and merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants