ApiaryActive
Try: pause · settings · learn · wipe
← Community / Reading Room
E
computing · 3 min read

Envoy

Envoy is an open-source edge and service proxy developed by Lyft and later donated to the Cloud Native Computing Foundation (CNCF). Written primarily in C++,…

Envoy is an open-source edge and service proxy developed by Lyft and later donated to the Cloud Native Computing Foundation (CNCF). Written primarily in C++, Envoy serves as a high-performance proxy designed for cloud-native applications, providing a robust platform for managing service-to-service communication, observability, and security in distributed systems.

Overview and Architecture

Envoy was originally created by Matt Klein at Lyft in 2016 to address the complexities of service-to-service communication in their microservices architecture. The proxy operates as a sidecar, running alongside application containers to handle all network communication. This design allows applications to remain unaware of the underlying network infrastructure while benefiting from advanced traffic management capabilities.

The architecture is built around a modular design that separates core proxying functionality from protocol-specific features. Envoy supports multiple architectures including x86_64, ARM64, and other platforms, making it suitable for diverse deployment environments from data centers to edge computing scenarios.

Core Features and Capabilities

Envoy provides HTTP/1.1, HTTP/2, and HTTP/3 support, enabling modern web communication standards. It includes advanced load balancing algorithms such as round-robin, least request, ring hash, and original destination routing. The proxy also implements sophisticated circuit breaking mechanisms to prevent cascading failures in distributed systems.

Traffic management features include request routing, retries, timeouts, and fault injection capabilities for testing system resilience. Envoy supports both outbound and inbound traffic management, making it suitable for both client-side and server-side proxy deployments.

Security features encompass mutual TLS authentication, certificate management, and authorization policies. The proxy integrates with various certificate authorities and supports automatic certificate rotation for maintaining secure communications.

Observability and Monitoring

One of Envoy's strongest aspects is its comprehensive observability stack. It generates detailed metrics covering traffic volume, latency distributions, and error rates. These metrics are exported in formats compatible with popular monitoring systems including Prometheus, StatsD, and DogStatsD.

Distributed tracing support enables end-to-end request tracking across service boundaries. Envoy integrates with tracing systems like Zipkin, Jaeger, and Datadog, automatically propagating trace context through HTTP headers. This capability is essential for debugging complex microservices interactions.

Access logging provides detailed records of all requests processed by the proxy, supporting various log formats and output destinations. The logging system can be configured to capture specific request and response attributes for security auditing and troubleshooting purposes.

Service Mesh Integration

Envoy serves as the data plane component for several prominent service meshes including Istio, Consul Connect, and AWS App Mesh. In these implementations, Envoy handles the actual packet processing while control plane components manage configuration distribution and policy enforcement.

The xDS (Discovery Service) API suite enables dynamic configuration management, allowing control planes to push routing rules, endpoint information, and security policies to Envoy instances in real-time. This API includes CDS (Cluster Discovery Service), EDS (Endpoint Discovery Service), LDS (Listener Discovery Service), RDS (Route Discovery Service), and SDS (Secret Discovery Service).

Performance and Scalability

Envoy is designed for high performance in production environments. Its event-driven architecture, built on the libevent library, efficiently handles thousands of concurrent connections with minimal resource overhead. The proxy supports connection pooling, request multiplexing, and various optimization techniques to maximize throughput while minimizing latency.

Resource management features include configurable connection limits, buffer sizes, and retry budgets to prevent resource exhaustion under heavy load. Envoy's hot restart capability allows configuration updates without dropping existing connections, ensuring zero-downtime operations.

The proxy includes sophisticated rate limiting capabilities, both local and global, to protect services from overload conditions. These features can be configured to operate on various request attributes including source IP, headers, and authentication principals.

Community and Ecosystem

Since joining the CNCF in 2017, Envoy has developed a large and active community of contributors and users. The project maintains regular release cycles with semantic versioning, providing stability guarantees for production deployments.

Extensive documentation, example configurations, and community support resources are available. The ecosystem includes various tools for configuration management, monitoring dashboards, and integration libraries for different programming languages.

Major cloud providers including Google Cloud, AWS, and Azure offer managed services built on Envoy, demonstrating its industry adoption. The proxy's flexibility and performance characteristics make it suitable for diverse use cases ranging from traditional load balancing to complex service mesh deployments in Kubernetes environments.

Frequently asked
What is Envoy about?
Envoy is an open-source edge and service proxy developed by Lyft and later donated to the Cloud Native Computing Foundation (CNCF). Written primarily in C++,…
What should you know about overview and Architecture?
Envoy was originally created by Matt Klein at Lyft in 2016 to address the complexities of service-to-service communication in their microservices architecture. The proxy operates as a sidecar, running alongside application containers to handle all network communication. This design allows applications to remain…
What should you know about core Features and Capabilities?
Envoy provides HTTP/1.1, HTTP/2, and HTTP/3 support, enabling modern web communication standards. It includes advanced load balancing algorithms such as round-robin, least request, ring hash, and original destination routing. The proxy also implements sophisticated circuit breaking mechanisms to prevent cascading…
What should you know about observability and Monitoring?
One of Envoy's strongest aspects is its comprehensive observability stack. It generates detailed metrics covering traffic volume, latency distributions, and error rates. These metrics are exported in formats compatible with popular monitoring systems including Prometheus, StatsD, and DogStatsD.
What should you know about service Mesh Integration?
Envoy serves as the data plane component for several prominent service meshes including Istio, Consul Connect, and AWS App Mesh. In these implementations, Envoy handles the actual packet processing while control plane components manage configuration distribution and policy enforcement.
References & sources
  1. Apiary Reading RoomOpen, cited knowledge base — funded to keep bee & practical research free.
From the Apiary Reading Room. Opinion & editorial — not financial advice. We don't overclaim.
More from the Reading Room