Skip to content

Commit ce6727b

Browse files
committed
Fix flaky Netty4Http3IT test suite (second attempt)
Signed-off-by: Andriy Redko <drreta@gmail.com>
1 parent cfebc67 commit ce6727b

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

modules/transport-netty4/src/test/java/org/opensearch/http/netty4/Netty4HttpClient.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@
3232

3333
package org.opensearch.http.netty4;
3434

35+
import org.apache.logging.log4j.LogManager;
36+
import org.apache.logging.log4j.Logger;
3537
import org.opensearch.common.TriFunction;
3638
import org.opensearch.common.collect.Tuple;
3739
import org.opensearch.common.settings.Settings;
@@ -117,7 +119,8 @@
117119
* Tiny helper to send http requests over netty.
118120
*/
119121
public class Netty4HttpClient implements Closeable {
120-
122+
private static final Logger logger = LogManager.getLogger(Netty4HttpClient.class);
123+
121124
static Collection<String> returnHttpResponseBodies(Collection<FullHttpResponse> responses) {
122125
List<String> list = new ArrayList<>(responses.size());
123126
for (FullHttpResponse response : responses) {
@@ -518,6 +521,8 @@ protected void initChannel(DatagramChannel ch) {
518521

519522
@Override
520523
Channel prepare(Bootstrap clientBootstrap, Channel channel) throws InterruptedException {
524+
logger.info("Connecting to: " + channel.remoteAddress());
525+
521526
final QuicChannel quicChannel = QuicChannel.newBootstrap(channel)
522527
.option(ChannelOption.CONNECT_TIMEOUT_MILLIS, 30000) // 30 seconds
523528
.handler(new Http3ClientConnectionHandler())

0 commit comments

Comments
 (0)