简介aiway (API and AI Gateway) 是一个基于 Rust 开发的高性能 API AI 网关致力于提供稳定、高效、可扩展的请求转发与管理解决方案。凭借 Rust 的内存安全特性和零成本抽象优势aiway 在保证高性能的同时提供了卓越的安全性和稳定性。平台支持Linux (x86_64 / arm64)macOS (arm64)openEuler (x86_64)UOS Server (x86_64)KylinOS (x86_64)协议支持HTTP/HTTPSSSEWebSocketMCP详细文档请访问aiway文档快速开始方式一使用预编译版本# 下载并解压curl-Lhttps://github.com/xgpxg/aiway/releases/latest/download/aiway-linux-amd64-standalone.tar.gz|tar-zxvf--C.# 启动服务./aiway注意预编译版本基于 glibc 2.34 构建如果您的系统glibc版本低于 2.34请从源码构建。方式二从源码构建# 构建 Gatewaycargobuild--bingateway-Fmodel-proxy,mcp-proxy# 构建 Consolecargobuild--binconsole# 构建 Loggcargobuild--binlogg# 运行cargorun--binaiway访问服务管理控制台: http://127.0.0.1:7000网关入口: http://127.0.0.1:7001默认账号: admin / admin核心功能动态路由 - 灵活配置请求路由规则服务管理 - 统一管理后端服务实例插件系统 - 可扩展的插件架构安全防护 - 内置防火墙和安全验证机制API Key 管理 - 统一的 API 密钥管理日志监控 - 完整的日志存储和实时监控可视化面板 - 直观的管理控制台AI 模型代理 - 智能 AI 模型代理和请求转发MCP 集成 - Model Context Protocol 支持插件生态官方插件我们提供了一系列常用插件访问 aiway-plugins 获取更多信息。自定义插件如需开发自定义插件请参考 插件开发文档。界面预览性能Ubuntu 24.04, Intel i7-12700K, 12 Cores, 16 GB RAMwrk http://127.0.0.1:7001/hello-t12-c100Running 10stest http://127.0.0.1:7001/hello12threads and100connections Thread Stats Avg Stdev Max /- Stdev Latency1.25ms574.88us10.34ms82.29% Req/Sec6.54k756.7814.64k86.22%784402requestsin10.10s,222.18MBreadRequests/sec:77662.06Transfer/sec:22.00MBopenEuler 24.03 (LTS-SP3), Intel® Xeon® 6982P-C, 4 Cores, 8 GB RAMRunning 10s test http://127.0.0.1:7001/hello 4 threads and 100 connections Thread Stats Avg Stdev Max /- Stdev Latency 3.80ms 1.22ms 13.60ms 70.35% Req/Sec 6.62k 380.06 7.43k 62.75% 263639 requests in 10.01s, 74.67MB read Requests/sec: 26332.11 Transfer/sec: 7.46MBUOS Server 20, Intel® Xeon® Platinum, 4 Cores, 8 GB RAMwrk http://127.0.0.1:7001/hello-t4-c100Running 10stest http://127.0.0.1:7001/hello8threads and100connections Thread Stats Avg Stdev Max /- Stdev Latency3.61ms2.48ms84.71ms93.78% Req/Sec3.47k452.1211.40k83.88%276965requestsin10.06s,78.45MBreadRequests/sec:27518.91Transfer/sec:7.79MB
【aiway】基于 Rust 开发的 API + AI 网关
简介aiway (API and AI Gateway) 是一个基于 Rust 开发的高性能 API AI 网关致力于提供稳定、高效、可扩展的请求转发与管理解决方案。凭借 Rust 的内存安全特性和零成本抽象优势aiway 在保证高性能的同时提供了卓越的安全性和稳定性。平台支持Linux (x86_64 / arm64)macOS (arm64)openEuler (x86_64)UOS Server (x86_64)KylinOS (x86_64)协议支持HTTP/HTTPSSSEWebSocketMCP详细文档请访问aiway文档快速开始方式一使用预编译版本# 下载并解压curl-Lhttps://github.com/xgpxg/aiway/releases/latest/download/aiway-linux-amd64-standalone.tar.gz|tar-zxvf--C.# 启动服务./aiway注意预编译版本基于 glibc 2.34 构建如果您的系统glibc版本低于 2.34请从源码构建。方式二从源码构建# 构建 Gatewaycargobuild--bingateway-Fmodel-proxy,mcp-proxy# 构建 Consolecargobuild--binconsole# 构建 Loggcargobuild--binlogg# 运行cargorun--binaiway访问服务管理控制台: http://127.0.0.1:7000网关入口: http://127.0.0.1:7001默认账号: admin / admin核心功能动态路由 - 灵活配置请求路由规则服务管理 - 统一管理后端服务实例插件系统 - 可扩展的插件架构安全防护 - 内置防火墙和安全验证机制API Key 管理 - 统一的 API 密钥管理日志监控 - 完整的日志存储和实时监控可视化面板 - 直观的管理控制台AI 模型代理 - 智能 AI 模型代理和请求转发MCP 集成 - Model Context Protocol 支持插件生态官方插件我们提供了一系列常用插件访问 aiway-plugins 获取更多信息。自定义插件如需开发自定义插件请参考 插件开发文档。界面预览性能Ubuntu 24.04, Intel i7-12700K, 12 Cores, 16 GB RAMwrk http://127.0.0.1:7001/hello-t12-c100Running 10stest http://127.0.0.1:7001/hello12threads and100connections Thread Stats Avg Stdev Max /- Stdev Latency1.25ms574.88us10.34ms82.29% Req/Sec6.54k756.7814.64k86.22%784402requestsin10.10s,222.18MBreadRequests/sec:77662.06Transfer/sec:22.00MBopenEuler 24.03 (LTS-SP3), Intel® Xeon® 6982P-C, 4 Cores, 8 GB RAMRunning 10s test http://127.0.0.1:7001/hello 4 threads and 100 connections Thread Stats Avg Stdev Max /- Stdev Latency 3.80ms 1.22ms 13.60ms 70.35% Req/Sec 6.62k 380.06 7.43k 62.75% 263639 requests in 10.01s, 74.67MB read Requests/sec: 26332.11 Transfer/sec: 7.46MBUOS Server 20, Intel® Xeon® Platinum, 4 Cores, 8 GB RAMwrk http://127.0.0.1:7001/hello-t4-c100Running 10stest http://127.0.0.1:7001/hello8threads and100connections Thread Stats Avg Stdev Max /- Stdev Latency3.61ms2.48ms84.71ms93.78% Req/Sec3.47k452.1211.40k83.88%276965requestsin10.06s,78.45MBreadRequests/sec:27518.91Transfer/sec:7.79MB