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

allow proxy to route based on request method #3526

Closed
wants to merge 2 commits into from

Conversation

butonic
Copy link
Member

@butonic butonic commented Apr 13, 2022

We added a method property to proxy routes that allows routing requests to a different backend.

We need this to route REPORT requests to the ocis webdav service to implement search

@update-docs
Copy link

update-docs bot commented Apr 13, 2022

Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes.

@butonic butonic marked this pull request as draft April 13, 2022 09:28
@butonic butonic force-pushed the proxy-method-routing branch 2 times, most recently from 01d1a4b to 2bee87b Compare April 13, 2022 09:36
@butonic butonic marked this pull request as ready for review April 13, 2022 09:37
@butonic butonic requested review from C0rby and wkloucek April 13, 2022 09:37
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
@ownclouders
Copy link
Contributor

ownclouders commented Apr 13, 2022

💥 Acceptance test Core-API-Tests-ocis-storage-1 failed. Further test are cancelled...

@@ -124,6 +125,7 @@ func (p *MultiHostReverseProxy) directorSelectionDirector(r *http.Request) {
return
}

method := ""
Copy link
Contributor

@C0rby C0rby Apr 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't fully wrap my head around this at the moment but shouldn't this be defined inside of the loop or at least be reset to an empty string at the beginning of the loop?

@sonarcloud
Copy link

sonarcloud bot commented Apr 14, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 3 Code Smells

57.9% 57.9% Coverage
0.0% 0.0% Duplication

@butonic
Copy link
Member Author

butonic commented May 9, 2022

merged as part of #3635

@butonic butonic closed this May 9, 2022
@butonic butonic deleted the proxy-method-routing branch May 9, 2022 11:34
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

Successfully merging this pull request may close these issues.

3 participants