Skip to content

pgwire: fix TestPGTest/large_input for shared process tenants#160502

Merged
craig[bot] merged 1 commit intocockroachdb:masterfrom
rafiss:mt-pgtest
Jan 6, 2026
Merged

pgwire: fix TestPGTest/large_input for shared process tenants#160502
craig[bot] merged 1 commit intocockroachdb:masterfrom
rafiss:mt-pgtest

Conversation

@rafiss
Copy link
Copy Markdown
Collaborator

@rafiss rafiss commented Jan 5, 2026

Previously, the TestPGTest/large_input test failed when running with a shared process virtual cluster because the cluster setting sql.conn.max_read_buffer_message_size was only set on the application tenant. In shared process mode, SQL connections come through the system tenant's pgwire listener, and the PreServeConnHandler uses the system tenant's settings to validate message sizes before routing to the appropriate tenant.

This commit fixes the test by also setting the cluster setting on the system tenant, ensuring that the message size limit is enforced correctly in both standalone and shared process modes.

Fixes: #112960
Epic: CRDB-48944

Release note: None

@rafiss rafiss requested review from a team as code owners January 5, 2026 22:03
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Previously, the TestPGTest/large_input test failed when running with
a shared process virtual cluster because the cluster setting
`sql.conn.max_read_buffer_message_size` was only set on the application
tenant. In shared process mode, SQL connections come through the system
tenant's pgwire listener, and the PreServeConnHandler uses the system
tenant's settings to validate message sizes before routing to the
appropriate tenant.

This commit fixes the test by also setting the cluster setting on the
system tenant, ensuring that the message size limit is enforced
correctly in both standalone and shared process modes.

Fixes: cockroachdb#112960
Epic: CRDB-48944

Release note: None
@rafiss rafiss requested a review from a team as a code owner January 6, 2026 04:17
@rafiss rafiss requested review from DrewKimball and removed request for a team January 6, 2026 04:17
Copy link
Copy Markdown
Member

@yuzefovich yuzefovich left a comment

Choose a reason for hiding this comment

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

Thanks!

@yuzefovich reviewed 2 files and all commit messages, and made 1 comment.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @DrewKimball).

@rafiss
Copy link
Copy Markdown
Collaborator Author

rafiss commented Jan 6, 2026

tftr!

bors r+

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Jan 6, 2026

@craig craig bot merged commit 0331673 into cockroachdb:master Jan 6, 2026
25 of 26 checks passed
@rafiss rafiss deleted the mt-pgtest branch January 7, 2026 00:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

sql: investigate why TestPGTest/large_input does not work with a shared process virtual cluster

3 participants