Copilot commented on code in PR #7211:
URL: https://github.com/apache/ignite-3/pull/7211#discussion_r2609357922
##########
modules/compatibility-tests/src/integrationTest/java/org/apache/ignite/internal/client/JdbcOverThinSqlWithOldServerCompatibilityTest.java:
##########
@@ -73,10 +75,13 @@ void jdbcConnectionToTheOldServerIsRejected() {
IgniteClientConnectionException connectEx =
(IgniteClientConnectionException) cause;
+ String expectedDriverVer =
Pattern.quote(IgniteProductVersion.CURRENT_VERSION.toString());
+
assertThat(connectEx.getMessage(),
- containsString("Connection to node aborted, because the node
does not support the feature required "
- + "by the driver being used. Please refer to the
documentation and use a compatible version "
- + "of the JDBC driver to connect to this node"));
+ matchesPattern("Connection to node aborted, because the node
does not support the feature required "
+ + "by the driver being used\\. Please refer to the
documentation and use a compatible version "
+ + "of the JDBC driver to connect to this node "
+ + "\\[nameName=.+, nodeAddress=.+, nodeVersion=.+,
driverVersion=" + expectedDriverVer + ']'));
Review Comment:
There's a typo in the test assertion pattern. It should be "nodeName"
instead of "nameName" to match the corrected error message format and properly
reflect that it refers to the node's name.
```suggestion
+ "\\[nodeName=.+, nodeAddress=.+, nodeVersion=.+,
driverVersion=" + expectedDriverVer + ']'));
```
##########
modules/jdbc/src/main/java/org/apache/ignite/jdbc/IgniteJdbcDriver.java:
##########
@@ -332,8 +336,8 @@ private TcpIgniteClient createIgniteClient(
IgniteStringFormatter.format("Connection to node
aborted, because the node does not support "
+ "the feature required by the driver being
used. Please refer to the documentation and use a compatible "
+ "version of the JDBC driver to connect to
this node "
- + "[name={}, address={}, productVersion={},
driverVersion={}.{}]",
- node.name(), node.address(),
ctx.productVersion(), getMajorVersion(), getMinorVersion()),
+ + "[nameName={}, nodeAddress={},
nodeVersion={}, driverVersion={}]",
Review Comment:
There's a typo in the format string parameter name. It should be "nodeName"
instead of "nameName" to properly reflect that it refers to the node's name.
```suggestion
+ "[nodeName={}, nodeAddress={},
nodeVersion={}, driverVersion={}]",
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]