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

Proxy support for Dropwizard HTTP client #657

Merged
merged 6 commits into from Apr 10, 2015

Conversation

Projects
None yet
5 participants
@arteam
Member

arteam commented Jul 12, 2014

I often encounter with a situation when in closed corporate environments direct access to the Internet is blocked by security reasons. So all connections to external resources happen through a proxy server (usually with BASIC authentication).

Deploying applications in such environments becomes a huge pain, because usually you don't know in advance that an application will need proxy connection support and sometimes you just don't have possibility to change code to add this facility.

I believe, it would be quite useful to have this facility in the Dropwizard config. It frees an application developer from thoughts about environments where an application will be used and shifts this responsibility to operations guys. And they can configure proxy client support just in the application config without using external tools.

PS I've added the docs to proxy configuration. But I'm not a skilled english speaker, so, please, fix them if I messed up something.

@jplock

This comment has been minimized.

Show comment
Hide comment
@jplock

jplock Jul 13, 2014

Member

+1

Member

jplock commented Jul 13, 2014

+1

@joschi joschi added the feature label Jul 13, 2014

@joschi joschi added this to the 0.8.0 milestone Jul 13, 2014

@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

View changes

Show outdated Hide outdated ...-client/src/main/java/io/dropwizard/client/proxy/ProxyConfiguration.java
@joschi

This comment has been minimized.

Show comment
Hide comment
@joschi

joschi Jul 13, 2014

Member

Thank you very much for this PR! Nicely documented. 😄

Member

joschi commented Jul 13, 2014

Thank you very much for this PR! Nicely documented. 😄

@arteam

This comment has been minimized.

Show comment
Hide comment
@arteam

arteam Jul 13, 2014

Member

Thanks for the review! I've tried to fix up things you mentioned.

Member

arteam commented Jul 13, 2014

Thanks for the review! I've tried to fix up things you mentioned.

@jplock

This comment has been minimized.

Show comment
Hide comment
@jplock

jplock Aug 8, 2014

Member

Any idea if this will get merged in?

Member

jplock commented Aug 8, 2014

Any idea if this will get merged in?

@philandstuff

This comment has been minimized.

Show comment
Hide comment
@philandstuff

philandstuff Aug 11, 2014

Contributor

I'm currently using DropWizard with a proxy server, but this PR wouldn't solve my problem because I need a whitelist of non-proxyable hosts on the local network. I have raised #681 as an alternative (not mutually exclusive) way to add proxy functionality. More details there.

Contributor

philandstuff commented Aug 11, 2014

I'm currently using DropWizard with a proxy server, but this PR wouldn't solve my problem because I need a whitelist of non-proxyable hosts on the local network. I have raised #681 as an alternative (not mutually exclusive) way to add proxy functionality. More details there.

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Sep 29, 2014

Coverage Status

Coverage increased (+0.71%) when pulling aeaca58 on arteam:proxy-support into a876b65 on dropwizard:master.

coveralls commented Sep 29, 2014

Coverage Status

Coverage increased (+0.71%) when pulling aeaca58 on arteam:proxy-support into a876b65 on dropwizard:master.

@arteam

This comment has been minimized.

Show comment
Hide comment
@arteam

arteam Sep 29, 2014

Member

I rebased the branch against the master and added a facility to configure non-proxyable hosts.

Does anyone interested in this type of configuration? If #681 is merged, then it would only a matter of taste of configuration type (YAML file or java properties).

Member

arteam commented Sep 29, 2014

I rebased the branch against the master and added a facility to configure non-proxyable hosts.

Does anyone interested in this type of configuration? If #681 is merged, then it would only a matter of taste of configuration type (YAML file or java properties).

@coveralls

This comment has been minimized.

Show comment
Hide comment
@coveralls

coveralls Sep 29, 2014

Coverage Status

Coverage increased (+0.71%) when pulling aeaca58 on arteam:proxy-support into a876b65 on dropwizard:master.

coveralls commented Sep 29, 2014

Coverage Status

Coverage increased (+0.71%) when pulling aeaca58 on arteam:proxy-support into a876b65 on dropwizard:master.

@arteam

This comment has been minimized.

Show comment
Hide comment
@arteam

arteam Jan 10, 2015

Member

I see #681 has been merged.

Is there any work needed for this PR? If Java properties configuration is sufficient then this PR could be closed or moved to a backlog from 0.8 release.

Member

arteam commented Jan 10, 2015

I see #681 has been merged.

Is there any work needed for this PR? If Java properties configuration is sufficient then this PR could be closed or moved to a backlog from 0.8 release.

@joschi joschi removed this from the 0.8.0 milestone Jan 17, 2015

@joschi

This comment has been minimized.

Show comment
Hide comment
@joschi

joschi Jan 17, 2015

Member

@arteam I'll move this PR out of the 0.8.0 milestone for now but I won't close it for now.

Maybe someone else wants to chime in whether the current state of affairs is sufficient or if this PR should be updated and merged.

Member

joschi commented Jan 17, 2015

@arteam I'll move this PR out of the 0.8.0 milestone for now but I won't close it for now.

Maybe someone else wants to chime in whether the current state of affairs is sufficient or if this PR should be updated and merged.

@jplock

This comment has been minimized.

Show comment
Hide comment
@jplock

jplock Apr 1, 2015

Member

@arteam did you want to update this for 0.9.0 or should we close this out?

Member

jplock commented Apr 1, 2015

@arteam did you want to update this for 0.9.0 or should we close this out?

arteam added some commits Jul 12, 2014

Code-review improvements of proxy configuration
- Use default values for the port and the scheme instead constants and methods getPresentPort and getPresentScheme
- Use @PortRange with min=-1 instead @range
- Use ignoreCase in @OneOf instead enumeration possible schemas in both cases.
- Reuse constructors
Migrations of proxy configuration to new API in the master
- Migration to Apache HTTP Client 4.3
- FEST -> AssertJ
@arteam

This comment has been minimized.

Show comment
Hide comment
@arteam

arteam Apr 10, 2015

Member

I've rebased this PR against master, it wasn't hard.

I just don't know if anyone need this feature apart me one year back :)

Member

arteam commented Apr 10, 2015

I've rebased this PR against master, it wasn't hard.

I just don't know if anyone need this feature apart me one year back :)

@jplock

This comment has been minimized.

Show comment
Hide comment
@jplock

jplock Apr 10, 2015

Member

I've got a few projects that are restricted to operating inside of an AWS VPC and need to communicate via a proxy, so I think this would be a great addition.

Member

jplock commented Apr 10, 2015

I've got a few projects that are restricted to operating inside of an AWS VPC and need to communicate via a proxy, so I think this would be a great addition.

jplock added a commit that referenced this pull request Apr 10, 2015

Merge pull request #657 from arteam/proxy-support
Proxy support for Dropwizard HTTP client

@jplock jplock merged commit 76542c0 into dropwizard:master Apr 10, 2015

@jplock jplock added this to the 0.9.0 milestone Apr 10, 2015

@jplock

This comment has been minimized.

Show comment
Hide comment
@jplock

jplock Apr 10, 2015

Member

Thanks a lot for this contribution!

Member

jplock commented Apr 10, 2015

Thanks a lot for this contribution!

@arteam arteam deleted the arteam:proxy-support branch Jan 24, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment