sso-proxy: refactor reverse proxy into separate file w/ tests#188
Merged
sso-proxy: refactor reverse proxy into separate file w/ tests#188
Conversation
Jusshersmith
reviewed
May 8, 2019
fb84b74 to
5af96bd
Compare
jphines
commented
May 20, 2019
9523d52 to
09df2b1
Compare
Jusshersmith
previously approved these changes
May 22, 2019
Contributor
Jusshersmith
left a comment
There was a problem hiding this comment.
This looks great @jphines!
09df2b1 to
75db6a3
Compare
shrayolacrayon
previously approved these changes
May 22, 2019
internal/proxy/reverse_proxy.go
Outdated
| } | ||
|
|
||
| if config.FlushInterval != 0 { | ||
| reverseProxy.FlushInterval = config.FlushInterval |
There was a problem hiding this comment.
do we have a default reverse proxy flush interval?
Contributor
Author
There was a problem hiding this comment.
We don't. 0 specifies no periodic flushing according to https://golang.org/pkg/net/http/httputil/ which is fine default behavior imho
internal/proxy/reverse_proxy.go
Outdated
| return handler, nil | ||
| } | ||
|
|
||
| // Director implements the Director func providerd in the httputil reverse proxy. |
internal/proxy/reverse_proxy.go
Outdated
| } | ||
|
|
||
| // Director implements the Director func providerd in the httputil reverse proxy. | ||
| // This implements a variety fo director behavior based on configuration defined |
fb05af4 to
4d788a6
Compare
shrayolacrayon
approved these changes
May 22, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Refactor reverse proxy and upstream into separate file w/ tests. Cleans up some of the reverse proxy logic.
This should make it easier to test reverse proxy specific features/changes in the future and help isolate the reverse proxy from the authentication/authorization portions of sso.
A split out from #187