Skip to content

Run hooks with websockets and rewrite ws headers #292

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

Merged
merged 11 commits into from
Mar 22, 2023

Conversation

mcollina
Copy link
Member

Checklist

@mcollina mcollina requested review from Eomm, Fdawgs and climba03003 and removed request for Fdawgs March 21, 2023 18:12
@mcollina mcollina requested a review from Uzlopak March 22, 2023 06:43
Copy link
Member

@Fdawgs Fdawgs left a comment

Choose a reason for hiding this comment

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

Few tweaks/questions

Co-authored-by: Frazer Smith <[email protected]>
@mcollina
Copy link
Member Author

@Fdawgs ptal

Signed-off-by: Matteo Collina <[email protected]>
Copy link
Member

@Fdawgs Fdawgs left a comment

Choose a reason for hiding this comment

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

LGTM on the docs front. Don't know enough about websockets to comment on functionality, but will leave that to the others to review!

Signed-off-by: Matteo Collina <[email protected]>
Signed-off-by: Matteo Collina <[email protected]>
@mcollina
Copy link
Member Author

Note that this also fixes a regression for the getUpstream() support for Websocket that was changed in fastify/fastify-reply-from#293

Copy link
Member

@Eomm Eomm left a comment

Choose a reason for hiding this comment

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

minor things - logic

Do you agree to release it as major?

if (request.headers.cookie) {
return { ...headers, cookie: request.headers.cookie }
}
return { ...headers }
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
return { ...headers }
return headers

Copy link
Member Author

Choose a reason for hiding this comment

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

This is deliberate to create a new object.

mcollina and others added 2 commits March 22, 2023 19:31
Co-authored-by: Manuel Spigolon <[email protected]>
Co-authored-by: Manuel Spigolon <[email protected]>
@mcollina
Copy link
Member Author

Yes, this should be a major.

Co-authored-by: Manuel Spigolon <[email protected]>
@mcollina mcollina merged commit 5723af1 into master Mar 22, 2023
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