Conversation
握手成功后通过 pg_is_in_recovery() 探测主机角色,角色不匹配 targetServerType 时销毁连接并跳到下一个候选 host。 - host-status-tracker: 区分已探测角色(MASTER/SLAVE)与待探测(CONNECT_OK) - host-chooser: 无候选时仅回退到可探测 host (isHostProbingCandidate) 修复 client.js 中阻断该功能的若干笔误: - _finalizeConnectSuccess 缺少调用括号,连接永远无法完成 - this.ConnectionParameters 大小写错误(应为 connectionParameters),握手时抛 TypeError - _conecting / _roleProdePending 拼写错误导致状态不归位与判断失效 - connectionError 漏写下划线 - 'fronyend protocol' 拼写、角色不匹配错误消息引号未闭合 另新增 unsupported frontend protocol 3.51 时以 protocolMinor:0 回退重连。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- host-status-tracker: _isHostSuitable / isHostProbingCandidate / getCandidateHosts (含 master/slave/preferSlave 移除 CONNECT_OK 的语义、preferSlave 优先 standby) - host-chooser: 无候选时的 probing fallback - client: _isRoleAcceptable / _finalizeConnectSuccess / 角色探测全流程 (匹配/不匹配/无法判定/probe出错/t-f字符串结果) / 协议回退(回退一次且不重复) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- client.js: 删除 const role 行尾多余空格 - target-server-type-tests.js: 协议回退测试长行换行 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
这些错误来自更早的 ut补充 / SHA256认证 提交,非本次 targetServerType
工作引入,但合并流水线跑全量 eslint 会因此失败。
- gaussdb-types.js / crypto-legacy-tests.js / inbound-parser.test.ts /
parser.ts: prettier 格式 (eslint --fix),parser.ts 仅删行尾空格
- gaussdb-types.js: 删除未使用的 parseFloatArray / parseBoolArray
(getTypeParser 无副作用且未导出)
- gaussdb-types-tests.js: require('../../../lib/defaults') 不再赋值给
未使用的 defaults 变量,保留 defaults.js 类型注册副作用
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
lint格式修复