fix(spi): replace hardcoded Chinese "成功" in JdbcUtils.testConnect wit… - #1900
Merged
openai0229 merged 1 commit intoJul 21, 2026
Merged
Conversation
…n message
JdbcUtils.testConnect set the connection-test result description to
the hardcoded Chinese string "成功", which is returned to the frontend
as-is via DataSourceConnect.description. Under non-Chinese locales
(en-US, es-ES, ko-KR) the UI would still display Chinese, breaking
i18n consistency.
The sibling class DefaultSQLExecutor uses the exact same pattern to
set success descriptions:
executeResult.setDescription(I18nUtils.getMessage("sqlResult.success"));
The i18n key `sqlResult.success` is already defined in all locale
resource bundles (zh_CN=执行成功, en_US=Execution successful, es_ES,
ko_KR, plus the default bundle). This change reuses the same key, so:
- Chinese users now see "执行成功" (consistent with SQL execution success)
- English / other-locale users see the properly localized message
- No new i18n keys are introduced
Change is 2 lines: add the existing import, replace the string literal.
liulipengju
force-pushed
the
fix/test-connect-i18n-hardcode
branch
from
July 21, 2026 08:56
405918a to
0e118b6
Compare
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.
Problem
JdbcUtils.testConnectset the connection-test result description to the hardcoded Chinese string"成功":