Feat/optimize logging - #1467
Conversation
Feat/monitor
fix slave metrics
Billing export
Feat/model search
Feat/adjust err
Billing optim
feat: support o3-deep-research-2025-06-26 model
1. 调整main.go中中间件执行顺序,将RequestId()放在RequestLogger()之前 2. 修改RequestLogger中间件,使用全链路上下文进行日志打印 3. 包含request ID和gin上下文信息,支持日志采样和错误统计 4. 修复Gemini相关功能和其他依赖更新
feat: 调整中间件执行顺序,实现全链路日志追踪
Feature/memory analysis
Feature/memory analysis
optimize metrics
|
Caution Review failedThe pull request is closed. WalkthroughThis update delivers a comprehensive refactor and feature expansion across backend, middleware, database, and frontend components. Major enhancements include: role-based access controls, batch job and billing features, daily log partitioning, advanced request/response logging, new relay channel types (including XAI and Doubao), metrics instrumentation, batch processing support for Volcengine, and numerous new API endpoints. The frontend is updated to support new filters, role-based data visibility, and billing export. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Frontend
participant API
participant Middleware
participant Controller
participant Model
participant DB
participant Volcengine
participant Redis
User->>Frontend: Interact (e.g., billing export, batch job)
Frontend->>API: Send request (with auth, filters)
API->>Middleware: Process request (logging, mock, auth)
Middleware->>Controller: Route to appropriate handler
Controller->>Model: Validate/request data (role/group aware)
Model->>DB: Query/update (logs, jobs, tokens, groups)
Controller->>Volcengine: (if batch job) Submit job/request presign
Controller->>Redis: (if batch job) Cache results/status
Controller->>Frontend: Return response (data, status, file)
Estimated code review effort🎯 5 (Critical) | ⏱️ ~90+ minutes Possibly related PRs
Suggested reviewers
Poem
Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. ✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
…service-cleanup refactor(channel): split long functions, extract shared validation, move billing validation to service
Summary by CodeRabbit
New Features
/ping).Improvements
Bug Fixes
Chores
Documentation
Style
Tests