Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[Rust-dataplane] Migration backend handshake must preserve CONNECT_WITH_DB when current-db empty

Đang mở Phù hợp với người mới
#1,358 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
64/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
go, rust
Lĩnh vực
backend, databases

Hướng nghiên cứu

Đọc rust/crates/dataplane/src/session_engine.rs quanh dòng 1270–1277 và so sánh cách xử lý capability với pkg/proxy/backend/authenticator.go quanh dòng 409–422. Bằng chứng cục bộ có tên run.tiproxy-rust-dataplane.migration-connect-db-capability.20260902.RED; hãy dùng nó để kiểm tra trường hợp cơ sở dữ liệu hiện tại trống. Hoàn tất khi Rust giữ lại CONNECT_WITH_DB trong backend handshake nếu client đã đàm phán capability này và backend hỗ trợ nó.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

migration:bb7133-tiproxy

Migrated from bb7133/tiproxy#194. Original author: wjhuang2016; created: 2026-09-02T12:43:20Z; source body SHA-256: 3398fb4a03b040cab2767263d631dfe5c0f3cc73b9ba8efd9eb814c39840f30e.

Rust dataplane rewrite parity/functional RED
  • Snapshot commit: 60efdf5e6e8226423df85033534ad748ccb129db
  • Run: run.tiproxy-rust-dataplane.migration-connect-db-capability.20260902.RED
Problem

Go writeAuthHandshake preserves CONNECT_WITH_DB in backend handshake regardless of DB value. Rust migration_auth_capabilities clears CONNECT_WITH_DB when has_database is false.

Claim

when original client negotiated CONNECT_WITH_DB and the migration backend supports it, Rust must keep CONNECT_WITH_DB even when current-db is empty.

Source anchors
  • pkg/proxy/backend/authenticator.go:409-422 writeAuthHandshake never clears CONNECT_WITH_DB
  • rust/crates/dataplane/src/session_engine.rs:1270-1277 migration_auth_capabilities clears on has_database false
Boundary
  • Before: Rust removes CONNECT_WITH_DB when current-db empty
  • After: Go sends CONNECT_WITH_DB with empty DB field
Local evidence
  • run.tiproxy-rust-dataplane.migration-connect-db-capability.20260902.RED
Ngôn ngữ chính
Go
Star
73
Fork
40
Merge trung bình
15 giờ 43 phút
Pull request đã merge (30 ngày)
9

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của pingcap/tiproxy

Tất cả issue của pingcap/tiproxy

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.