Skip to content

test(frontend): cover prepared numeric protocol lifecycle - #25893

Merged
mergify[bot] merged 5 commits into
matrixorigin:mainfrom
ck89119:issue-25753-main
Jul 21, 2026
Merged

mergify[bot] merged 5 commits into
matrixorigin:mainfrom
ck89119:issue-25753-main

Conversation

@ck89119

@ck89119 ck89119 commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

What type of PR is this?

  • API-change
  • BUG
  • Improvement
  • Documentation
  • Feature
  • Test and CI
  • Code Refactoring

Which issue(s) this PR fixes:

Fixes #25753

What this PR does / why we need it:

Adds end-to-end coverage for the numeric prepared-statement protocol lifecycle.

The integration test forces go-sql-driver/mysql to use real
COM_STMT_PREPARE, COM_STMT_EXECUTE, and COM_STMT_CLOSE packets and reuses
one server-side statement across signed integers, unsigned integers, strings,
NULLs, and client parameter type changes. It verifies exact values above
2^53, parameter count metadata, DECIMAL result metadata, stable conversion
errors, statement reuse after errors, and explicit cleanup.

The BVT covers the SQL PREPARE/EXECUTE lifecycle, repeated execution, numeric
transport changes, NULLs, signed and unsigned values, conversion failures, and
successful reuse after a failure. DML assignment-context cases remain scoped to
#25752 and are intentionally not duplicated here.

Validation:

  • TestIssue25753PreparedNumericProtocolLifecycle
  • full ./pkg/frontend unit tests
  • prepared numeric planner unit tests
  • go vet for affected and dependent packages with the repository CGo setup
  • make build
  • mo-tester: 31/31 statements passed
  • git diff --check

@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@XuPeng-SH XuPeng-SH left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No blocking findings on the latest head.

The prepared-statement protocol coverage now exercises the real COM_STMT_PREPARE / EXECUTE / CLOSE lifecycle end to end, and the small frontend fixes line up with that coverage: prepare metadata now carries the expected character attributes, and joined MySQL errors preserve the intended server error code / SQLSTATE while keeping the full message text. I did not find a new correctness or unhappy-path blocker in the updated diff.

@gouhongshen gouhongshen left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codex automated review

No correctness, compatibility, concurrency, resource, performance, unhappy-path, or coverage regressions found. Existing discussion had no unresolved findings, and current-head CI passed the new protocol lifecycle test and BVT coverage.

@mergify mergify Bot added the queued label Jul 21, 2026
@mergify

mergify Bot commented Jul 21, 2026 •

Copy link
Copy Markdown
Contributor

Merge Queue Status

  • ✅ Entered queue — 2026-07-21 03:46 UTC · Rule: main · triggered by rule Automatic queue on approval for main
  • ✅ Checks passed · in-place
  • ✅ Merged — 2026-07-21 05:43 UTC · at e62b20e00bc06f192b3f29d0fb87f8dcf45b48f2 · squash

This pull request spent 1 hour 56 minutes 12 seconds in the queue, including 59 minutes 53 seconds running CI.

Required conditions to merge
  • #review-threads-unresolved = 0 [🛡 GitHub branch protection]
  • github-review-approved [🛡 GitHub branch protection] (documentation)
  • github-review-decision = APPROVED [🛡 GitHub branch protection] (documentation)
  • any of [🛡 GitHub branch protection]:
    • check-success = Matrixone Compose CI / multi cn e2e bvt test docker compose(PESSIMISTIC)
    • check-neutral = Matrixone Compose CI / multi cn e2e bvt test docker compose(PESSIMISTIC)
    • check-skipped = Matrixone Compose CI / multi cn e2e bvt test docker compose(PESSIMISTIC)
  • any of [🛡 GitHub branch protection]:
    • check-success = Matrixone Standlone CI / Multi-CN e2e BVT Test on Linux/x64(LAUNCH, PROXY)
    • check-neutral = Matrixone Standlone CI / Multi-CN e2e BVT Test on Linux/x64(LAUNCH, PROXY)
    • check-skipped = Matrixone Standlone CI / Multi-CN e2e BVT Test on Linux/x64(LAUNCH, PROXY)
  • any of [🛡 GitHub branch protection]:
    • check-success = Matrixone Standlone CI / e2e BVT Test on Linux/x64(LAUNCH, PESSIMISTIC)
    • check-neutral = Matrixone Standlone CI / e2e BVT Test on Linux/x64(LAUNCH, PESSIMISTIC)
    • check-skipped = Matrixone Standlone CI / e2e BVT Test on Linux/x64(LAUNCH, PESSIMISTIC)
  • any of [🛡 GitHub branch protection]:
    • check-success = Matrixone CI / UT Test on Ubuntu/x86
    • check-neutral = Matrixone CI / UT Test on Ubuntu/x86
    • check-skipped = Matrixone CI / UT Test on Ubuntu/x86
  • any of [🛡 GitHub branch protection]:
    • check-success = Matrixone Utils CI / Coverage
    • check-neutral = Matrixone Utils CI / Coverage
    • check-skipped = Matrixone Utils CI / Coverage
  • any of [🛡 GitHub branch protection]:
    • check-success = Matrixone CI / SCA Test on Linux/arm64
    • check-neutral = Matrixone CI / SCA Test on Linux/arm64
    • check-skipped = Matrixone CI / SCA Test on Linux/arm64

@mergify
mergify Bot merged commit c3a6791 into matrixorigin:main Jul 21, 2026
23 of 24 checks passed
@mergify mergify Bot removed the queued label Jul 21, 2026
@ck89119
ck89119 deleted the issue-25753-main branch July 21, 2026 06:01
VioletQwQ-0 pushed a commit to VioletQwQ-0/matrixone that referenced this pull request Sep 17, 2026
…in#25893)

Adds end-to-end coverage for the numeric prepared-statement protocol lifecycle.

The integration test forces `go-sql-driver/mysql` to use real
`COM_STMT_PREPARE`, `COM_STMT_EXECUTE`, and `COM_STMT_CLOSE` packets and reuses
one server-side statement across signed integers, unsigned integers, strings,
NULLs, and client parameter type changes. It verifies exact values above
`2^53`, parameter count metadata, DECIMAL result metadata, stable conversion
errors, statement reuse after errors, and explicit cleanup.

The BVT covers the SQL PREPARE/EXECUTE lifecycle, repeated execution, numeric
transport changes, NULLs, signed and unsigned values, conversion failures, and
successful reuse after a failure. DML assignment-context cases remain scoped to
matrixorigin#25752 and are intentionally not duplicated here.

Validation:

- `TestIssue25753PreparedNumericProtocolLifecycle`
- full `./pkg/frontend` unit tests
- prepared numeric planner unit tests
- `go vet` for affected and dependent packages with the repository CGo setup
- `make build`
- mo-tester: 31/31 statements passed
- `git diff --check`

Approved by: @XuPeng-SH, @gouhongshen, @heni02
VioletQwQ-0 pushed a commit to VioletQwQ-0/matrixone that referenced this pull request Sep 17, 2026
…in#25893)

Adds end-to-end coverage for the numeric prepared-statement protocol lifecycle.

The integration test forces `go-sql-driver/mysql` to use real
`COM_STMT_PREPARE`, `COM_STMT_EXECUTE`, and `COM_STMT_CLOSE` packets and reuses
one server-side statement across signed integers, unsigned integers, strings,
NULLs, and client parameter type changes. It verifies exact values above
`2^53`, parameter count metadata, DECIMAL result metadata, stable conversion
errors, statement reuse after errors, and explicit cleanup.

The BVT covers the SQL PREPARE/EXECUTE lifecycle, repeated execution, numeric
transport changes, NULLs, signed and unsigned values, conversion failures, and
successful reuse after a failure. DML assignment-context cases remain scoped to
matrixorigin#25752 and are intentionally not duplicated here.

Validation:

- `TestIssue25753PreparedNumericProtocolLifecycle`
- full `./pkg/frontend` unit tests
- prepared numeric planner unit tests
- `go vet` for affected and dependent packages with the repository CGo setup
- `make build`
- mo-tester: 31/31 statements passed
- `git diff --check`

Approved by: @XuPeng-SH, @gouhongshen, @heni02
VioletQwQ-0 pushed a commit to VioletQwQ-0/matrixone that referenced this pull request Sep 17, 2026
…in#25893)

Adds end-to-end coverage for the numeric prepared-statement protocol lifecycle.

The integration test forces `go-sql-driver/mysql` to use real
`COM_STMT_PREPARE`, `COM_STMT_EXECUTE`, and `COM_STMT_CLOSE` packets and reuses
one server-side statement across signed integers, unsigned integers, strings,
NULLs, and client parameter type changes. It verifies exact values above
`2^53`, parameter count metadata, DECIMAL result metadata, stable conversion
errors, statement reuse after errors, and explicit cleanup.

The BVT covers the SQL PREPARE/EXECUTE lifecycle, repeated execution, numeric
transport changes, NULLs, signed and unsigned values, conversion failures, and
successful reuse after a failure. DML assignment-context cases remain scoped to
matrixorigin#25752 and are intentionally not duplicated here.

Validation:

- `TestIssue25753PreparedNumericProtocolLifecycle`
- full `./pkg/frontend` unit tests
- prepared numeric planner unit tests
- `go vet` for affected and dependent packages with the repository CGo setup
- `make build`
- mo-tester: 31/31 statements passed
- `git diff --check`

Approved by: @XuPeng-SH, @gouhongshen, @heni02

This branch was previously deployed

1 inactive deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/test-ci size/M Denotes a PR that changes [100,499] lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Subtask]: close the prepared numeric protocol lifecycle

4 participants