zentol commented on a change in pull request #18509:
URL: https://github.com/apache/flink/pull/18509#discussion_r793569273
##########
File path:
flink-connectors/flink-connector-cassandra/src/test/java/org/apache/flink/streaming/connectors/cassandra/CassandraConnectorITCase.java
##########
@@ -237,6 +245,30 @@ public static void startAndInitializeCassandra() {
CREATE_TABLE_QUERY.replace(TABLE_NAME_VARIABLE,
TABLE_NAME_PREFIX + "initial"));
}
+ private static void raiseCassandraRequestsTimeouts() {
+ try {
+ final Path configurationPath = TEMPORARY_FOLDER.newFile().toPath();
+ CASSANDRA_CONTAINER.copyFileFromContainer(
+ "/etc/cassandra/cassandra.yaml",
configurationPath.toAbsolutePath().toString());
+ String configuration =
+ new String(Files.readAllBytes(configurationPath),
StandardCharsets.UTF_8);
+ String patchedConfiguration =
+ configuration
+ .replace("request_timeout_in_ms: 10000",
"request_timeout_in_ms: 30000")
+ .replace(
+ "read_request_timeout_in_ms: 5000",
+ "read_request_timeout_in_ms: 15000")
+ .replace(
+ "write_request_timeout_in_ms: 2000",
+ "write_request_timeout_in_ms: 6000");
Review comment:
I think doing it in the config is fine.
We could add safeguards that the replacements actually do something (e.g.,
check that the string is different) if we really want to be on the safe side.
--
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]