servicetalk icon indicating copy to clipboard operation
servicetalk copied to clipboard

Naming inconsistencies for HTTP filters

Open NiteshKant opened this issue 7 years ago • 1 comments

HTTP APIs follow the convention:

  • For aggregated APIs (non-streaming): No qualification is present in the names. eg: HttpRequest, HttpResponse.
  • For async streaming APIs: We prefix with Streaming. eg: StreamingHttpRequest, StreamingHttpResponse
  • For blocking streaming APIs: We prefix with BlockingStreaming. eg: BlockingStreamingHttpRequest, BlockingStreamingHttpResponse

However, we only provide ways to add async streaming filters, so we drop the qualification in the name. eg: TracingHttpServiceFilter extends StreamingHttpService but it does not have a name qualification according to the above convention. The rational is to reduce naming verbosity at the cost of not following the conventions.

Not following conventions can cause confusion for users and we should revisit to see if we can reduce this confusion.

NiteshKant avatar Oct 11 '18 20:10 NiteshKant

Some relevant discussion here: https://github.com/servicetalk/servicetalk/pull/112#discussion_r223803835

NiteshKant avatar Oct 11 '18 20:10 NiteshKant