opentracing-contrib / java-web-servlet-filter

OpenTracing Java Web Servlet Filter Instrumentation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Keep interface clean

sydneyhenrard opened this issue · comments

I noticed that several interfaces have anonymous implementation in it.

  • STANDARD_TAGS in ServletFilterSpanDecorator
  • STANDARD_LOGS in HandlerInterceptorSpanDecorator
  • HANDLER_METHOD_OPERATION_NAME in HandlerInterceptorSpanDecorator

Is there a reason?

I wanted to add queryString to Tags.HTTP_URL but since I can't extend STANDARD_TAGS, I have to create my own class and copy paste all methods and change what I need. If I could extend the class, I could have just override onRequest.

There is no reason. We could provide a class which can be overridden.

Are you willing to submit a PR. I would like to keep the constants to be backwards compatible.