Is it possible to set common client and server filter via plugin


#1

Is it possible to set common client and server filter via plugin?
For example there is a io.buoyant.router.http.TracingFilter which applied to client.
I want to develop custom tracing filter for client and server. But looks like there is no way to inject it.

`


#2

That’s correct, there isn’t a way to inject arbitrary filters via plugin. Can you tell us a bit more about your use-case?


#3

I’m trying to add support for OpenTracing API (http://opentracing.io/).
For that I need to have access to http headers of incoming and outgoing requests.
My idea is to have a Filter which will

  1. Extract span context from http headers of incoming requests (and later use this context as parent for created span)
  2. Create span and inject it into http headers of outgoing request.
  3. Call Trace.recordBinary("opentracing-span", span). It will be intercepted by OpenTracing linkerd plugin (using TelemeterInitializer)

I can create Pull Request if you would like to look at my approach.


#4

This discussion has moved to GitHub: https://github.com/linkerd/linkerd/pull/1773