aimeric/axum-demo

By aimeric

Updated about 6 hours ago

Simple rust web api to demonstrate axum framework capabilities.

Image
Networking

422

Web API to demonstrate axum capabilities

Axum is a web framework that is supported by the tokio team. It integrate natively with the tower and tower-http ecosystem, so we can use middleware, services, and utilities with axum. Moreover, we can also use this with other framework that work with tower like hyper for http and tonic for grpc.

Features

  • RFC 7807 compliant for all error message
  • OpenAPI docs
  • Traces export to an otel backend in the otlp format
  • Graceful Shutdown for sending last traces before the application stop
  • Expose metrics in the prometheus format at /metrics
  • Visualize data with grafana
  • Timout
  • Rate Limiting
  • Serve static file
  • Health check routes
  • Rest Routes
  • RPC routes
  • Auth with cookies and jwt

Docker Pull Command

docker pull aimeric/axum-demo