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

Http refactor #3842

Merged
merged 7 commits into from
Apr 28, 2021
Merged

Http refactor #3842

merged 7 commits into from
Apr 28, 2021

Conversation

innovate-invent
Copy link
Contributor

@innovate-invent innovate-invent commented Jan 2, 2020

What is the purpose of this change?

Refactor http server code to abstract away the http server from the http services.

Was the change discussed in an issue or in the forum before?

https://forum.rclone.org/t/http-upload-contribution/13271/34

Checklist

  • I have read the contribution guidelines.
  • I have added tests for all changes in this PR if appropriate.
  • I have added documentation for the changes if appropriate.
  • All commit messages are in house style.
  • I'm done, this Pull Request is ready for review :-)

lib/http/http.go Outdated Show resolved Hide resolved
lib/http/auth/basic.go Show resolved Hide resolved
cmd/serve/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Show resolved Hide resolved
lib/http/http.go Show resolved Hide resolved
lib/http/auth/basic.go Show resolved Hide resolved
lib/http/auth/basic.go Show resolved Hide resolved
lib/http/auth/basic.go Show resolved Hide resolved
lib/http/auth/basic.go Show resolved Hide resolved
lib/http/auth/basic.go Outdated Show resolved Hide resolved
@innovate-invent innovate-invent force-pushed the http_refactor branch 2 times, most recently from 052935d to e0eb25d Compare January 2, 2020 01:04
lib/http/auth/basic.go Outdated Show resolved Hide resolved
lib/http/auth/basic.go Outdated Show resolved Hide resolved
lib/http/auth/basic.go Outdated Show resolved Hide resolved
lib/http/auth/basic.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
@innovate-invent innovate-invent force-pushed the http_refactor branch 2 times, most recently from 4ffba70 to a434215 Compare January 2, 2020 01:21
lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
@innovate-invent innovate-invent force-pushed the http_refactor branch 3 times, most recently from 7ad626a to fc2f498 Compare January 2, 2020 01:37
lib/http/auth/auth.go Outdated Show resolved Hide resolved
@innovate-invent innovate-invent force-pushed the http_refactor branch 2 times, most recently from 16f6a8d to 8eac907 Compare January 2, 2020 02:08
@innovate-invent
Copy link
Contributor Author

The failure is possibly due to golangci/golangci-lint#138

@ivandeex
Copy link
Member

ivandeex commented Dec 3, 2020

@innovate-invent
May I help you with rebasing this on master?

@innovate-invent
Copy link
Contributor Author

@ivandeex absolutely, thanks

@ncw
Copy link
Member

ncw commented Apr 19, 2021

Is this getting squash merged or should I rewrite the commit history?

If you can re-write the commit history into a small number of logical changes then it will make it much easier to review and it will look good in the commit log. I think this change (which is quite big) should probably be more than one commit. Thanks

@innovate-invent
Copy link
Contributor Author

@ncw @ivandeex should be ready to merge

@ncw
Copy link
Member

ncw commented Apr 22, 2021

Can you rebase it on master to get rid of the merge commit?

I need to give this another review - will try to find time this week.

@innovate-invent
Copy link
Contributor Author

I'll rebase, but master is a moving target

@innovate-invent innovate-invent force-pushed the http_refactor branch 4 times, most recently from 9c92342 to 5dec9a1 Compare April 23, 2021 21:06
@innovate-invent
Copy link
Contributor Author

@ncw Just pushed a minor tweak and now it is saying you need to approve workflows?

Copy link
Member

@ncw ncw left a comment

Choose a reason for hiding this comment

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

I think this is looking very good :-)

It is a nice re-organization of the http code.

I put a small number of minor comments inline for you to take a look at.

lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Outdated Show resolved Hide resolved
lib/http/http.go Show resolved Hide resolved
cmd/serve/httplib/httplib.go Show resolved Hide resolved
Copy link
Member

@ncw ncw left a comment

Choose a reason for hiding this comment

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

I'm happy with these changes now so I'll merge them now :-)

Can you fix the conflict first though? Rebase on master should do it.

Thanks

@innovate-invent
Copy link
Contributor Author

innovate-invent commented Apr 28, 2021

Rebase completed, I'll open PRs refactoring the other services ASAP.

@ncw
Copy link
Member

ncw commented Apr 28, 2021

I'll merge that now.

Thank you for your great work and sorry it has taken so long to merge.

Look forward to the next commits in the series :-)

Thanks

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

Successfully merging this pull request may close these issues.

4 participants