Apache APISIX — Cloud Native High-Performance API Gateway
Apache APISIX is a dynamic, real-time, high-performance API gateway built on NGINX and etcd, offering rich traffic management with a large plugin ecosystem and sub-millisecond routing updates.
What it is
Apache APISIX is a dynamic, real-time, high-performance API gateway built on NGINX and etcd. It provides rich traffic management features including load balancing, rate limiting, authentication, and observability through a large plugin ecosystem. Routes and plugins update in sub-millisecond time without server restarts.
It is designed for platform teams and API developers who need a production-grade gateway with dynamic configuration, multi-protocol support (HTTP, gRPC, WebSocket, MQTT), and extensibility via Lua or external plugins.
How it saves time or tokens
Traditional gateways require config file edits and process reloads to apply routing changes. APISIX stores all configuration in etcd and pushes updates to NGINX workers in real time. Adding a new route, enabling rate limiting, or switching upstream targets happens through an admin API call without downtime. The plugin marketplace covers common needs -- JWT auth, CORS, Prometheus metrics, fault injection -- so you rarely write custom code.
How to use
- Start APISIX with Docker Compose.
git clone https://github.com/apache/apisix-docker
cd apisix-docker/example
docker compose -p apisix up -d
- Create a route via the admin API.
curl -i http://127.0.0.1:9180/apisix/admin/routes/1 \
-H 'X-API-KEY: edd1c9f034335f136f87ad84b625c8f1' \
-X PUT -d '{
"uri": "/get",
"upstream": { "type": "roundrobin", "nodes": {"httpbin.org:80": 1} }
}'
- Test the route.
curl http://127.0.0.1:9080/get
Example
Adding rate limiting to a route:
curl http://127.0.0.1:9180/apisix/admin/routes/1 \
-H 'X-API-KEY: edd1c9f034335f136f87ad84b625c8f1' \
-X PATCH -d '{
"plugins": {
"limit-req": {
"rate": 10,
"burst": 5,
"key_type": "var",
"key": "remote_addr",
"rejected_code": 429
}
}
}'
The rate limit takes effect immediately without restarting the gateway.
Related on TokRepo
- DevOps tools -- Infrastructure tools for API management and deployment.
- Monitoring tools -- Observability plugins that integrate with APISIX.
Common pitfalls
- The default admin API key is publicly known. Change it immediately in production by editing
conf/config.yaml. - etcd is a required dependency. If etcd becomes unavailable, APISIX continues serving with cached config but cannot accept new route changes.
- Custom Lua plugins run inside the NGINX worker process. CPU-intensive plugins can block request handling. Use external plugin runners for heavy computation.
Frequently Asked Questions
Both are NGINX-based API gateways. APISIX uses etcd for configuration storage (sub-millisecond updates), while Kong uses PostgreSQL or Cassandra (slower propagation). APISIX is an Apache Software Foundation project; Kong is backed by Kong Inc. with both open-source and enterprise tiers.
Yes. APISIX can proxy gRPC traffic, perform gRPC-to-HTTP transcoding, and apply plugins (auth, rate limiting) to gRPC services the same way it handles HTTP routes.
Yes. Plugins can be written in Lua (runs inside NGINX), or as external processes in Python, Go, or Java using the plugin runner protocol. Lua plugins have the lowest latency; external plugins offer language flexibility.
Yes. APISIX is open source under the Apache 2.0 license. There is no paid tier from the Apache project itself. Some vendors offer commercial support and management dashboards.
The APISIX Dashboard is an optional web UI for managing routes, upstreams, and plugins visually. It communicates with APISIX through the admin API and is distributed as a separate Docker image.
Citations (3)
- Apache APISIX GitHub— Apache APISIX is built on NGINX and etcd with dynamic routing
- APISIX Documentation— Sub-millisecond routing updates without restarts
- ASF Projects— Apache Software Foundation top-level project
Related on TokRepo
Discussion
Related Assets
doctest — The Fastest Feature-Rich C++ Testing Framework
doctest is a single-header C++ testing framework designed for minimal compile-time overhead and maximum speed.
Chai — BDD/TDD Assertion Library for Node.js
Chai is a flexible assertion library for Node.js and browsers that supports expect, should, and assert styles.
Supertest — HTTP Assertion Library for Node.js APIs
Supertest provides a high-level API for testing HTTP servers in Node.js with fluent assertion chaining.