Developer Guides
Intro
Gloo Gateway invites developers to extend Gloo Gateway’s functionality and adapt to new use cases via the addition of plugins.
Gloo Gateway’s plugin based architecture makes it easy to extend functionality in a variety of areas:
- Gloo Gateway’s API: extensible through the use of Protocol Buffers along with Solo-Kit
- Service Discovery Plugins: automatically discover service endpoints from catalogs such as Kubernetes and Consul
- Function Discovery Plugins: annotate services with information discovered by polling services directly (such as OpenAPI endpoints and gRPC methods).
- Routing Plugins: customize what happens to requests when they match a route or virtual host
- Upstream Plugins: customize what happens to requests when they are routed to a service
- Operators for Configuration: Gloo Gateway exposes its intermediate language for proxy configuration via the Proxy Custom Resource, allowing operators to leverage Gloo Gateway for multiple use cases. With the optional Gloo Gateway GraphQL module, you can set up API gateway and GraphQL server functionality for your apps, without running in the same process (or even the same container) as Gloo Gateway.
Gloo Gateway API Concepts
-
v1.Proxies provide the routing configuration which Gloo Gateway will translate and apply to Envoy.
-
v1.Upstreams describe routable destinations for Gloo Gateway.
-
Proxies represent a unified configuration to be applied to one or more instances of a proxy. You can think of the proxy of as tree like such:
proxy ├─ bind-address │ ├── domain-set │ │ ├── /route │ │ ├── /route │ │ ├── /route │ │ └── tls-config │ └── domain-set │ ├── /route │ ├── /route │ ├── /route │ └── tls-config └─ bind-address ├── domain-set │ ├── /route │ ├── /route │ ├── /route │ └── tls-config └── domain-set ├── /route ├── /route ├── /route └── tls-config
A single proxy CRD contains all the configuration necessary to be applied to an instance of Envoy. In the Gloo Gateway system, Proxies are treated as an intermediary representation of config, while user-facing config is imported from simpler, more opinionated resources such as the gateway.solo.io.VirtualService or Kubernetes Ingress objects.
For this reason, a standard Gloo Gateway deployment contains one or more controllers which programmatically generate and write these CRDs to provide simpler, use-case specific APIs such as API Gateway and Ingress. You can extend these capabilities even more with Gloo Gateway modules, such as Gloo Gateway GraphQL. This optional module is an advanced controller which creates routing configuration for Gloo Gateway from GraphQL Schemas.
-
Upstreams represent destinations for routing requests in Gloo Gateway. Routes in Gloo Gateway specify one or more Upstreams (by name) as their destination. Upstreams have a
type
which is provided in theirupstreamSpec
field. Each type of upstream corresponds to an Upstream Plugin, which tells Gloo Gateway how to translate upstreams of that type to Envoy clusters. When a route is declared for an upstream, Gloo Gateway invokes the corresponding plugin for that type
Guides
This Section includes the following developer guides:
-
Building External Auth Plugins: Guidelines and best practices for developing and configuring Go plugins to extend Gloo Gateway's ext auth server
Note: the Controller tutorial does not require modifying any Gloo Gateway code.