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

Add hook for redirect function in ServeHTTP #939

Closed
wants to merge 1 commit into from

Conversation

aharshit29
Copy link

To migrate direct callers of edge-gateway to api-gateway-http, a flipr controlled gate is needed. This PR adds a hook in Zanzibar Router's ServeHTTP function so that a redirect function can be plugged in, to redirect the requests (received for a particular endpoint) to api-gateway-http instead of passing through edge-gateway.

This cannot be done at middleware level as ServeHTTP function also emits endpoint metrics which should not be emitted if the requests are being served by api-gateway-http.

@CLAassistant
Copy link

CLAassistant commented Oct 8, 2024

CLA assistant check
All committers have signed the CLA.

@aharshit29 aharshit29 force-pushed the redirect-event-hook branch from eb2e43b to 5f8ea9c Compare October 8, 2024 18:02
@aharshit29 aharshit29 closed this Oct 9, 2024
@aharshit29 aharshit29 deleted the redirect-event-hook branch October 9, 2024 04:38
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.

2 participants