Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/swift-otel/swift-otel

OpenTelemetry client built for Swift observability libraries
https://github.com/swift-otel/swift-otel

distributed-tracing metrics opentelemetry opentelemetry-swift swift swift-distributed-tracing swift-metrics swift-otel tracing

Last synced: 11 minutes ago
JSON representation

OpenTelemetry client built for Swift observability libraries

Awesome Lists containing this project

README

        

# Swift OTel

An [OpenTelemetry](https://opentelemetry.io) client for server-side Swift.

[![Swift Package Index](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fswift-otel%2Fswift-otel%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/swift-otel/swift-otel)
[![codecov](https://codecov.io/gh/swift-otel/swift-otel/graph/badge.svg?token=CLBHHQITUY)](https://codecov.io/gh/swift-otel/swift-otel)

## Examples

Swift OTel comes with a couple examples to demonstrate how to get started and how to go beyond the basics:

### Example 1: [Counter](./Examples/Counter)

This example contains an endless running service that keeps counting up a number after a randomized delay.
The increments are traced and exported to [Jaeger](https://jaegertracing.io).

### Example 2: [Server](./Examples/Server)

An example HTTP server built using [Hummingbird](https://github.com/hummingbird-project/hummingbird) and its middleware
for Metrics and Distributed Tracing. Each incoming request is automatically instrumented with a span and metrics such
as the request duration are recorded. Both metrics and traces are sent to an OTel Collector via Swift OTel.