Skip to content

feat: add ability to skip validation checks - #66

Merged
mromaszewicz merged 3 commits into
mainfrom
feat/skipper
Apr 3, 2026
Merged

mromaszewicz merged 3 commits into
mainfrom
feat/skipper

Conversation

@jamietanna

@jamietanna jamietanna commented Feb 8, 2026 •

Copy link
Copy Markdown
Member

As noted in #63, an equivalent to Echo's Skipper would allow for
middleware users to opt-out of validation in a more straightforward way.

In a slightly different implementation to our echo-middleware, this
does not allow the Skipper to consume the body of the original
request, and instead duplicates it for the Skipper, and the other uses
of it.

@jamietanna jamietanna linked an issue Feb 8, 2026 that may be closed by this pull request
As noted in #63, an equivalent to Echo's `Skipper` would allow for
middleware users to opt-out of validation in a more straightforward way.

In a slightly different implementation to our `echo-middleware`, this
does not allow the `Skipper` to consume the body of the original
request, and instead duplicates it for the `Skipper`, and the other uses
of it.

Closes #63.
@jamietanna
jamietanna marked this pull request as ready for review February 8, 2026 19:09
@jamietanna
jamietanna requested a review from a team as a code owner February 8, 2026 19:09
@jamietanna

Copy link
Copy Markdown
Member Author

@GreyXor how does this look?

@GreyXor

GreyXor commented Feb 10, 2026 •

Copy link
Copy Markdown
Contributor

@GreyXor how does this look?

LGTM! :)

Comment thread oapi_validate.go Resolved
@GreyXor

GreyXor commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

Hi @jamietanna
do we miss something to merge it? thanks!

mromaszewicz and others added 2 commits April 2, 2026 16:50
Resolve conflicts between feat/skipper and the Prefix feature from main.
Both features are independent and retained in full.

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
Remove copyHTTPRequest which eagerly called io.ReadAll on every request
body when a Skipper was configured. This caused unnecessary memory
allocation for large/streaming bodies and silently swallowed read errors.

Pass the original request directly to the Skipper, matching the pattern
used by echo-middleware. If a Skipper needs to inspect the body, it is
responsible for managing consumption — but most Skippers only need the
path or headers.

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
@mromaszewicz
mromaszewicz merged commit 08dfb43 into main Apr 3, 2026
29 checks passed
@mromaszewicz
mromaszewicz deleted the feat/skipper branch April 3, 2026 00:07
@mromaszewicz mromaszewicz added the bug Something isn't working label Jul 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Equivalent of Echo skipper ?

3 participants