camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen (JIRA)" <j...@apache.org>
Subject [jira] Updated: (CAMEL-380) camel-mina UDP protocol fails when sending bytes
Date Sun, 09 Mar 2008 13:32:35 GMT

     [ https://issues.apache.org/activemq/browse/CAMEL-380?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Claus Ibsen updated CAMEL-380:
------------------------------

    Attachment: camel_380_patch.txt

The patch that fixes:
- this bug with bytes
- improved unit testing
- the 2 removed codelines in MinaComponent that converts to ByteBuffer is already handled
by the first line in the method (convertTo).


> camel-mina UDP protocol fails when sending bytes
> ------------------------------------------------
>
>                 Key: CAMEL-380
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-380
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mina
>    Affects Versions: 1.3.0
>            Reporter: Claus Ibsen
>         Attachments: camel_380_patch.txt
>
>
> Using a CamelProducer to send bytes to a mina UDP listener fails.
> This unit tests below fails
> Using: "Hello from bytes" as a plain string works fine.
> {code}
>     public void testSendingByteMessages() throws Exception {
>         MockEndpoint endpoint = getMockEndpoint("mock:result");
>         endpoint.expectedMessageCount(1);
>         template.sendBody("mina:udp://127.0.0.1:4445", "Hello from bytes".getBytes());
>         // sleeping for while to let the mock endpoint get all the message
>         Thread.sleep(1000);
>         assertMockEndpointsSatisifed();
>         List<Exchange> list = endpoint.getReceivedExchanges();
>         assertEquals("Hello from bytes", list.get(0).getIn().getBody(String.class));
>     }
> {code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message