Guillaume Nodet created CAMEL-23253:
---------------------------------------

             Summary: LangChain4jEmbeddingsComponentInfinispanTargetIT is flaky 
due to Infinispan Hot Rod connection timeout
                 Key: CAMEL-23253
                 URL: https://issues.apache.org/jira/browse/CAMEL-23253
             Project: Camel
          Issue Type: Bug
          Components: camel-langchain4j-embeddings
            Reporter: Guillaume Nodet


The integration test {{LangChain4jEmbeddingsComponentInfinispanTargetIT}} in 
{{camel-langchain4j-embeddings}} is flaky on CI. It fails intermittently with 
an Infinispan Hot Rod {{SocketTimeoutException}} (2000ms timeout) when trying 
to connect to the testcontainer.

The failure cascade:
# {{CachePingOperation}} times out after 2000ms connecting to Infinispan
# {{FailedToStartRouteException}} is thrown because the route cannot start
# Subsequent test methods fail with {{RejectedExecutionException: CamelContext 
is stopped}}

Stack trace:
{code}
org.apache.camel.FailedToStartRouteException: Failed to start route: route1 
because: org.infinispan.client.hotrod.exceptions.TransportException:: 
java.net.SocketTimeoutException: 
RetryingHotRodOperation{delegate=CachePingOperation{___protobuf_metadata, 
flags=0}...} timed out after 2000 ms
{code}

Observed on JDK 25 CI build for PR #21994 
([run|https://github.com/apache/camel/actions/runs/23535611086/job/68552019353]).
 JDK 17 and JDK 21 builds passed.

Possible fixes:
* Increase the Hot Rod client connection timeout for the test
* Add retry logic for the testcontainer readiness check
* Add {{@Timeout}} or conditional skip when the container is not ready



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to