Skip to content

Yelp/swagger_zipkin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

92e8715 · Nov 2, 2022

History

56 Commits
Oct 19, 2022
Oct 19, 2022
Oct 25, 2022
Oct 19, 2022
Oct 25, 2022
Oct 19, 2022
Oct 25, 2022
Aug 1, 2017
Oct 25, 2022
Oct 25, 2022
Oct 25, 2022
Oct 25, 2022
Nov 2, 2022
Oct 25, 2022

Repository files navigation

Github Actions build PyPi version Supported Python versions

swagger_zipkin

swagger_zipkin contains zipkin integration tools for instrumenting downstream service calls made using bravado or swagger-py http clients.

It is aimed to be a standalone package, with only dependency being py_zipkin.

Quick Start

The decorator can be applied to any swagger-py or bravado client. The example shows a sample usage on bravado. It assume the code is being called from within a py_zipkin.zipkin.zipkin_span context manager or decorator.

from bravado.client import SwaggerClient
from swagger_zipkin.zipkin_decorator import ZipkinClientDecorator

client = SwaggerClient.from_url("http://petstore.swagger.io/v2/swagger.json")
zipkin_wrapped_client = ZipkinClientDecorator(client)

pet = zipkin_wrapped_client.pet.getPetById(petId=42).result()