wangxlong commented on a change in pull request #14377:
URL: https://github.com/apache/flink/pull/14377#discussion_r545149366
##########
File path:
flink-connectors/flink-connector-jdbc/src/test/java/org/apache/flink/connector/jdbc/table/JdbcTableSourceSinkFactoryTest.java
##########
@@ -255,6 +255,17 @@ public void testJdbcValidation() {
fail("exception expected");
} catch (IllegalArgumentException ignored) {
}
+
+ // lookup max-retries properties not complete
Review comment:
// lookup max-retries property less than zero
##########
File path:
flink-connectors/flink-connector-jdbc/src/test/java/org/apache/flink/connector/jdbc/table/JdbcLookupTableITCase.java
##########
@@ -120,7 +120,7 @@ public void testLookup() throws Exception {
.build());
if (useCache) {
Review comment:
Would be better as following,
> JdbcLookupOptions.Builder lookupOptionsBuilder =
JdbcLookupOptions.builder().setMaxRetryTimes(0);
if (useCache) {
lookupOptionsBuilder.setCacheMaxSize(1000).setCacheExpireMs(1000 * 1000);
}
builder.setLookupOptions(lookupOptionsBuilder.build());
##########
File path:
flink-connectors/flink-connector-jdbc/src/main/java/org/apache/flink/table/descriptors/JdbcValidator.java
##########
@@ -115,7 +115,7 @@ private void validateReadProperties(DescriptorProperties
properties) {
private void validateLookupProperties(DescriptorProperties properties) {
properties.validateLong(CONNECTOR_LOOKUP_CACHE_MAX_ROWS, true);
properties.validateDuration(CONNECTOR_LOOKUP_CACHE_TTL, true,
1);
- properties.validateInt(CONNECTOR_LOOKUP_MAX_RETRIES, true);
+ properties.validateInt(CONNECTOR_LOOKUP_MAX_RETRIES, true,0);
Review comment:
Space is needed before 0.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]