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

Moved middleware into server package #1007

Merged
merged 3 commits into from Nov 4, 2021
Merged

Conversation

josecordaz
Copy link
Contributor

@josecordaz josecordaz commented Nov 2, 2021

Closes: #955

What changed?
Moved middleware into server package

Why?
Improve code organization

How did you test it?
CI tests

Release notes

Documentation Changes

@josecordaz josecordaz added the type/enhancement New feature or request label Nov 2, 2021
@josecordaz josecordaz changed the title Moved middleware to pkg/server instead to avoid conflict with referen… Moved middleware into server package Nov 2, 2021
@josecordaz josecordaz marked this pull request as ready for review November 2, 2021 15:59
Copy link
Contributor

@jpellizzari jpellizzari left a comment

Choose a reason for hiding this comment

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

I disagree with the premise of the original ticket (cc @JamWils), but the AC was to NOT have middleware accessible outside of the server packaage. That said, I don't think this should be in internal.

The middleware was split into it's own package so other HTTP server implementations could share the middleware behavior. We will need to move it back out again if we ever add a new HTTP service.

In any case, this change is fine for now as it removes another top-level pkg directory.

# Conflicts:
#	pkg/server/server_test.go
@josecordaz josecordaz merged commit 99539b8 into main Nov 4, 2021
@josecordaz josecordaz deleted the 955-move-middleware-server-pkg branch November 4, 2021 15:28
joshri pushed a commit that referenced this pull request Nov 4, 2021
* Moved middleware to pkg/server instead to avoid conflict with reference inside integration folder

* Removed old import to internal/middleware
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move middleware into server package
2 participants