Skip to content

Conversation

@mpls104
Copy link
Contributor

@mpls104 mpls104 commented Nov 7, 2022

resolve #841

Copy link
Contributor

@stevenh stevenh left a comment

Choose a reason for hiding this comment

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

LGTM

@jamietanna
Copy link
Member

Thanks for this - looks like this was because I copy-pasta'd Chi's server, and was resolved there in #787

@jamietanna jamietanna self-requested a review November 12, 2022 20:44
Copy link
Member

@jamietanna jamietanna left a comment

Choose a reason for hiding this comment

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

Looks good - only requested change is that similar to the Chi PR, we add a compatibility option to allow folks to opt-in to these?

@mpls104
Copy link
Contributor Author

mpls104 commented Nov 15, 2022

@jamietanna
Addressed in 4b9090f

@mpls104 mpls104 requested a review from jamietanna November 16, 2022 03:00
Copy link
Member

@jamietanna jamietanna left a comment

Choose a reason for hiding this comment

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

Looks good, thanks for the changes 🙌

Only thought I have is whether we should rename the flag:

-apply-gorilla-mux-middleware-first-to-last
+apply-gorilla-middleware-first-to-last

Given the configuration to generate gorilla/mux servers is gorilla-server?

@mpls104
Copy link
Contributor Author

mpls104 commented Dec 7, 2022

Understood. Since GenerateOptions has already named as gorilla-server, let's omit the word mux. I'll push commit to fix them.

@mpls104 mpls104 requested a review from jamietanna December 7, 2022 10:33
@deepmap-marcinr deepmap-marcinr merged commit ab90f19 into oapi-codegen:master Dec 17, 2022
@mpls104 mpls104 deleted the reverse_gorilla_middleware branch January 5, 2023 05:43
adrianpk pushed a commit to foorester/oapi-codegen that referenced this pull request Jan 16, 2024
…implementation (oapi-codegen#842)

* Reverse the order of the middleware when they apopted in gorilla/mux implementation

* Add config to keep compatibility

* Rename option by omitting
adrianpk added a commit to foorester/oapi-codegen that referenced this pull request May 31, 2024
…implementation (oapi-codegen#842)

* Reverse the order of the middleware when they apopted in gorilla/mux implementation

* Add config to keep compatibility

* Rename option by omitting
danicc097 pushed a commit to danicc097/oapi-codegen that referenced this pull request Aug 31, 2024
…implementation (oapi-codegen#842)

* Reverse the order of the middleware when they apopted in gorilla/mux implementation

* Add config to keep compatibility

* Rename option by omitting
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.

The order of the middlewares is reversed in gorilla/mux implementation

4 participants