Fix incorrect ParameterStatus key casing for DateStyle, TimeZone, and IntervalStyle#5146
Conversation
…valStyle These parameters use capitalized names in PostgreSQL for historical reasons. ProxySQL now sends them using canonical capitalization to ensure client compatibility.
Summary of ChangesHello @rahim-kanji, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses a critical compatibility issue with PostgreSQL clients that are sensitive to the casing of Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request correctly addresses an issue with the case-sensitivity of certain PostgreSQL ParameterStatus message names by updating DateStyle, TimeZone, and IntervalStyle to use their canonical capitalized forms. The changes are logical and well-implemented, ensuring that client-facing communication uses the correct capitalization while internal matching remains case-insensitive. The related adjustments in other files improve code robustness. I have one suggestion to enhance the variable matching logic for better correctness and clarity.
83596fa to
dc6db35
Compare
|



Summary
PostgreSQL clients treat
ParameterStatusmessage names as case-sensitive and expect canonical capitalization for certain parameters.Three parameters in PostgreSQL use capitalized names instead of lowercase for historical reasons:
DateStyleTimeZoneIntervalStyleThese parameters predate the unified GUC (Grand Unified Configuration) system and retained their mixed-case names for backward compatibility.
Because ProxySQL previously sent them as
datestyle,timezone, andintervalstyle, some PostgreSQL clients failed to recognize them and ignored their values.Fix
DateStyle,TimeZone, andIntervalStyle.ParameterStatuskeys continue to use lowercase names, consistent with PostgreSQL.Closes #5145