Skip to content

Fix possible protocol desync with SchemaOnly and auto prepare#5221

Merged
vonzshik merged 1 commit intomainfrom
5220-schema-only-auto-prepare-protocol-desync-fix
Aug 25, 2023
Merged

Fix possible protocol desync with SchemaOnly and auto prepare#5221
vonzshik merged 1 commit intomainfrom
5220-schema-only-auto-prepare-protocol-desync-fix

Conversation

@vonzshik
Copy link
Copy Markdown
Contributor

Fixes #5220

@vonzshik vonzshik requested a review from roji as a code owner August 25, 2023 13:16
throw Connector.UnexpectedMessageReceived(msg.Code);
}

if (_statements.Skip(StatementIndex + 1).All(x => x.IsPrepared))
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

cc @NinoFloris added linq here (which from what I aware you removed in separate pr)

Would prefer to leave as is in this pr to make it a bit easier to backport.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Sure, I'll have to rebase the rework at least once more anyway

@vonzshik vonzshik enabled auto-merge (squash) August 25, 2023 15:11
@vonzshik vonzshik disabled auto-merge August 25, 2023 15:13
Copy link
Copy Markdown
Member

@NinoFloris NinoFloris left a comment

Choose a reason for hiding this comment

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

Alright let's merge it in. Will rebase on top of all of this

@vonzshik vonzshik merged commit 8c0e93b into main Aug 25, 2023
@vonzshik vonzshik deleted the 5220-schema-only-auto-prepare-protocol-desync-fix branch August 25, 2023 15:35
vonzshik added a commit that referenced this pull request Aug 25, 2023
vonzshik added a commit that referenced this pull request Aug 25, 2023
Fixes #5220

(cherry picked from commit 8c0e93b)

# Conflicts:
#	src/Npgsql/NpgsqlDataReader.cs
@vonzshik
Copy link
Copy Markdown
Contributor Author

Backported to 7.0.6 via 8060929, 6.0.10 via 6a8081d (no 5.0 because it depends on non-backported #4420).

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Protocol desync with CommandBehavior.SchemaOnly and auto prepare

2 participants