Skip to content

Latest commit

 

History

History
58 lines (33 loc) · 2.72 KB

Clients.md

File metadata and controls

58 lines (33 loc) · 2.72 KB

Clients

Patron microservices can interact with other microservices, APIs and applications using a number of clients.

All clients contain integrated tracing powered by opentracing-go; any new clients should attempt to do the same.

Third-party dependencies
github.com/opentracing/opentracing-go v1.1.0

HTTP Client

Patron provides an HTTP client which integrates tracing into all outgoing requests by wrapping the default net/http client. Users can configure the client's Timeout, RoundTripper and/or set up a circuit breaker.

AMQP

The AMQP client allows users to connect to a RabbitMQ instance and publish JSON or Protobuf messages using a fan-out exchange. The published messages have integrated tracing headers by default. Users can configure the timeout for connecting to the RabbitMQ instance.

Third-party dependencies
github.com/streadway/amqp v0.0.0-20180315184602-8e4aba63da9f

gRPC

The gRPC client initiates a client connection to a given target while injecting a UnaryInterceptor to integrate tracing capabilities. By default, this is a non-blocking connection and users can pass in any number of grpc.DialOption arguments to configure its behavior.

Third-party dependencies
google.golang.org/grpc v1.27.1

Kafka

The Kafka client allows users to create a synchronous or asynchronous Kafka producer and publish Kafka messages with tracing headers. The builder pattern allows users to configure the Kafka version, the dial timeout, the RequiredAcks policy, as well as the encoder used to serialize the messages.

Third-party dependencies
github.com/Shopify/sarama v1.21.0

Redis

The Redis client allows users to connect to a Redis instance and execute commands. The connection can be configured using redis.Options.

Third-party dependencies
github.com/go-redis/redis/v7 v7.0.0-beta.5

SQL

The SQL client enhances the standard library SQL by integrating tracing capabilities. It has support for prepared statements, queries, as well as low-level handling of transactions.

SNS - SQS

The SNS and SQS clients provide a set of interfaces and structs useful for publishing messages to AWS SNS and SQS, with integrating tracing.

Third-party dependencies
github.com/aws/aws-sdk-go v1.21.8

Elasticsearch

The Elasticsearch client allows users to connect to an elasticsearch instance. Its behavior can be configured by providing an elasticsearch.Config struct

Third-party dependencies
github.com/elastic/go-elasticsearch/v8 v8.0.0-20190731061900-ea052088db25