sandynz commented on code in PR #24026:
URL: https://github.com/apache/shardingsphere/pull/24026#discussion_r1098594560
##########
test/e2e/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/data/pipeline/framework/helper/PipelineCaseHelper.java:
##########
@@ -102,8 +102,21 @@ private static String generateString(final int strLength) {
return RandomStringUtils.randomAlphabetic(strLength);
}
- private static String generateJsonString(final int strLength) {
- return String.format("{\"test\":\"%s\"}", generateString(strLength));
+ /**
+ * Generate json string.
+ *
+ * @param useUnicodeCharacter use unicode character
+ * @param strLength string length
+ * @return json string
+ */
+ public static String generateJsonString(final int strLength, final boolean
useUnicodeCharacter) {
Review Comment:
`strLength` could be `length`
##########
test/e2e/pipeline/src/test/java/org/apache/shardingsphere/test/e2e/data/pipeline/cases/base/PipelineBaseE2EIT.java:
##########
@@ -201,9 +201,13 @@ protected void addResource(final String distSQL) throws
SQLException {
}
protected String appendExtraParam(final String jdbcUrl) {
- return DatabaseTypeUtil.isMySQL(getDatabaseType())
- ? new JdbcUrlAppender().appendQueryProperties(jdbcUrl,
PropertiesBuilder.build(new Property("rewriteBatchedStatements",
Boolean.TRUE.toString())))
- : jdbcUrl;
+ if (DatabaseTypeUtil.isMySQL(getDatabaseType())) {
+ return new JdbcUrlAppender().appendQueryProperties(jdbcUrl,
PropertiesBuilder.build(new Property("rewriteBatchedStatements",
Boolean.TRUE.toString())));
+ }
+ if (DatabaseTypeUtil.isPostgreSQL(getDatabaseType()) ||
DatabaseTypeUtil.isOpenGauss(getDatabaseType())) {
+ return new JdbcUrlAppender().appendQueryProperties(jdbcUrl,
PropertiesBuilder.build(new Property("stringtype", "unspecified")));
+ }
+ return jdbcUrl;
Review Comment:
`jdbcUrl` should be `result`
--
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]