5 unstable releases
new 0.3.2 | Mar 21, 2025 |
---|---|
0.3.1 | Jan 28, 2025 |
0.3.0 | Jan 27, 2025 |
0.2.1 | Dec 10, 2024 |
0.1.0 | Nov 7, 2024 |
#6 in #dynamically
Used in 2 crates
12KB
239 lines
Overview
An xDS dynamically-configurable API load-balancer library.
What is it?
Junction is a library that allows you to dynamically configure application level HTTP routing, load balancing, and resilience by writing a few lines of configuration and dynamically pushing it to your client. Imagine all of the features of a rich HTTP proxy that's as easy to work with as the HTTP library you're already using.
Junction does that by pulling endpoints and configuration from an xDS control plane, as follows:
┌─────────────────────┐
│ Client Service │
├──────────┬──────────┤ ┌───────────┐
│ Existing │ Junction ◄────┤ xDS │
│ HTTP │ Client │ │ Control │
│ Library │ Library │ │ Plane │
└────┬─┬───┴──────────┘ └─────▲─────┘
│ │ │
│ └──────────┐ │
┌────▼────┐ ┌────▼────┐ ┌─────┴─────┐
│ Your │ │ Your │ │ K8s API │
│ Service │ │ Service │ │ Server │
└─────────┘ └─────────┘ └───────────┘
Junction is developed by Junction Labs.
Features
Today, Junction allows you to dynamically configure:
- Routing traffic based on HTTP method, path, headers, or query parameters
- Timeouts
- Retries
- Weighted traffic splitting
- Load balancing (Ring-Hash or WRR)
On our roadmap are features like:
- multi-cluster federation
- zone-based load balancing
- rate limiting
- subsetting
- circuit breaking
Supported xDS Control Planes
Today the only xDS server the junction-client regression tests against is
ezbake, developed by Junction Labs. ezbake is a simple xDS control plane for
Junction, which uses the gateway_api to support dynamic configuration.
ezbake
runs in a Kubernetes cluster, watches its running services, and creates
the xds configuration to drive the Junction Client.
Supported languages and HTTP Libraries
Language | Integrated HTTP Libraries |
---|---|
Rust | None |
Python | requests, urllib3 |
Node.js | fetch() |
Getting started
Project status
Junction is alpha software, developed in the open. We're still iterating rapidly on our client facing API, and our integration into xDS. At this stage you should expect occasional breaking changes as the library evolves.
License
The Junction client is Apache 2.0 licensed.
Contact Us
lib.rs
:
This crate defines an extremely basic reflection API, for use in
junction-client
. It does not have a stable public API, and will not be
checked for breaking changes. Use it at your own risk.
Dependencies
~315–740KB
~18K SLoC