Aurélien Pupier created CAMEL-22148:
---------------------------------------

             Summary: InterceptSendToEndpoint is not working on Windows when 
using regex
                 Key: CAMEL-22148
                 URL: https://issues.apache.org/jira/browse/CAMEL-22148
             Project: Camel
          Issue Type: Bug
          Components: camel-core
    Affects Versions: 4.12.0
            Reporter: Aurélien Pupier
         Attachments: image-2025-06-05-15-10-21-979.png

revealed by the test:

{noformat}
java.lang.AssertionError: mock://detour Received message count. Expected: <2> 
but was: <0>
        at 
org.apache.camel.component.mock.MockEndpoint.fail(MockEndpoint.java:2057)
        at 
org.apache.camel.component.mock.MockEndpoint.assertEquals(MockEndpoint.java:1992)
        at 
org.apache.camel.component.mock.MockEndpoint.doAssertIsSatisfied(MockEndpoint.java:495)
        at 
org.apache.camel.component.mock.MockEndpoint.assertIsSatisfied(MockEndpoint.java:473)
        at 
org.apache.camel.component.mock.MockEndpoint.assertIsSatisfied(MockEndpoint.java:463)
        at 
org.apache.camel.component.mock.MockEndpoint.assertIsSatisfied(MockEndpoint.java:262)
        at 
org.apache.camel.ContextTestSupport.assertMockEndpointsSatisfied(ContextTestSupport.java:900)
        at 
org.apache.camel.processor.intercept.InterceptSendToEndpointDynamicTest.testSendToRegex(InterceptSendToEndpointDynamicTest.java:104)
        at java.base/java.lang.reflect.Method.invoke(Method.java:568)
        at 
java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
        at 
java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
        at 
java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
        at 
java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
        at 
java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
{noformat}

On Windows, the matching is not working because several characters are encoded 
when th epattern matching is attempted:
 !image-2025-06-05-15-10-21-979.png|thumbnail! 



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

Reply via email to