sfhardman / kong-plugin-zipkin

Kong plugin to simulate clients and/or servers where these cannot practically be instrumented directly
Apache License 2.0
31 stars 9 forks source link

Support Zipkin v2 format #4

Open shakuzen opened 6 years ago

shakuzen commented 6 years ago

Right now, it appears this plugin supports the v1 format. It would be nice if it supports the simplified v2 format going forward.

The v2 format is described in the Zipkin server's API documentation: https://zipkin.io/zipkin-api/#/default/post_spans

shakuzen commented 6 years ago

You can find more information about Zipkin's v2 span model at https://github.com/openzipkin/zipkin/issues/1499. The Zipkin server has accepted this format on the /v2 API endpoints since version 1.30

sfhardman commented 6 years ago

Agreed, this would be a good idea. I'm unlikely to get to it in the near future though. Happy to take a PR

shakuzen commented 6 years ago

@sfhardman Would you prefer to replace the current v1 support with v2 support? The advice for those that need to use v1 format would be to use the previous version of this plugin (0.1.0). Otherwise, support for both would have to coexist with a configuration option to pick which is used, and that adds complexity.

I don't have any experience with Kong or Lua, so I'd rather someone else make the PR (any takers?), but I would be happy to review things from a Zipkin perspective.

sfhardman commented 6 years ago

I'd probably go for retaining both, with a config flag that defaults to v1.