feat: track upstream request ID and prevent response header override

When proxying through another new-api instance, the upstream
X-Oneapi-Request-Id was overwriting the local one in client responses.
This adds a new `upstream_request_id` field to the logs table, captures
the upstream ID during relay, and filters it from being copied back to
the client. Frontend gains search/filter and detail display support.
This commit is contained in:
CaIon
2026-05-12 21:53:54 +08:00
parent 428e3d91f2
commit aa56667b8f
20 changed files with 112 additions and 32 deletions
+4 -3
View File
@@ -1817,6 +1817,7 @@
"Generation quality preset": "Mức chất lượng sinh",
"Generic cache": "Bộ đệm chung",
"Get notified when balance falls below this value": "Nhận thông báo khi số dư giảm xuống dưới giá trị này",
"Get one here": "Nhận tại đây",
"Get started": "Bắt đầu",
"Get Started": "Bắt đầu",
"GitHub": "GitHub",
@@ -2059,7 +2060,6 @@
"IP Filter Mode": "Lọc IP",
"IP Restriction": "Giới hạn IP",
"IP Whitelist (supports CIDR)": "Danh sách trắng IP (hỗ trợ CIDR)",
"Power AI applications, manage digital assets, connect the Future": "Vận hành ứng dụng AI, quản lý tài sản số, kết nối Tương lai",
"is less than the configured maximum cache size": "nhỏ hơn kích thước bộ nhớ đệm tối đa đã cấu hình",
"is the default price; ": "là giá mặc định; ",
"It seems like the page you're looking for": "Có vẻ như trang bạn đang tìm kiếm",
@@ -2946,6 +2946,7 @@
"PostgreSQL detected": "Phát hiện PostgreSQL",
"PostgreSQL offers advanced reliability and data integrity for production workloads.": "PostgreSQL cung cấp độ tin cậy cao và tính toàn vẹn dữ liệu cho khối lượng công việc production.",
"PostgreSQL offers strong reliability guarantees. Double check your maintenance window and retention policies before going live.": "PostgreSQL cung cấp các đảm bảo độ tin cậy cao. Hãy kiểm tra kỹ lưỡng cửa sổ bảo trì và các chính sách lưu giữ của bạn trước khi vận hành chính thức.",
"Power AI applications, manage digital assets, connect the Future": "Vận hành ứng dụng AI, quản lý tài sản số, kết nối Tương lai",
"Powerful API Management Platform": "Nền tảng Quản lý API mạnh mẽ",
"Pre-Consume for Free Models": "Dùng trước các mô hình miễn phí",
"Pre-consumed": "Khấu trừ trước",
@@ -3073,8 +3074,6 @@
"Pull": "Tải",
"Pull model": "Tải mô hình",
"Pulling...": "Đang tải...",
"Subscribe to a plan for model access": "Đăng ký gói để truy cập mô hình",
"Get one here": "Nhận tại đây",
"Purchase Limit": "Giới hạn mua",
"Purchase limit reached": "Đã đạt giới hạn mua",
"Purchase Subscription": "Mua gói đăng ký",
@@ -3702,6 +3701,7 @@
"Submitting...": "Đang gửi...",
"Submodel": "Submodel",
"Subscribe Now": "Đăng ký ngay",
"Subscribe to a plan for model access": "Đăng ký gói để truy cập mô hình",
"Subscription": "Đăng ký",
"Subscription Billing": "Thanh toán gói đăng ký",
"Subscription First": "Ưu tiên đăng ký",
@@ -4140,6 +4140,7 @@
"Upstream price sync": "Đồng bộ giá thượng nguồn",
"Upstream prices fetched successfully": "Lấy giá upstream thành công",
"Upstream ratios fetched successfully": "Đã lấy tỷ lệ upstream thành công",
"Upstream Request ID": "ID yêu cầu thượng nguồn",
"Upstream Response": "Upstream feedback",
"upstream services integrated": "dịch vụ thượng nguồn tích hợp",
"Upstream Updates": "Cập nhật nguồn",