echauchot commented on a change in pull request #18509:
URL: https://github.com/apache/flink/pull/18509#discussion_r793570837



##########
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:
       Fair enough, I'll add an UTest that reads the file again to test the 
replacements.




-- 
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]


Reply via email to