Skip to content

Apply tower layer/middleware only on one service #1200

Answered by LucioFranco
harscoet asked this question in Q&A
Discussion options

You must be logged in to vote

I would check the incoming path of the http request and match on that. Each service provides a https://docs.rs/tonic/latest/tonic/server/trait.NamedService.html trait impl that you can use to match only on that one inbound services requests.

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@harscoet
Comment options

Answer selected by harscoet
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants