You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by "Bed�rftig, Arne via users" <us...@camel.apache.org> on 2026/02/27 10:24:04 UTC
Upgrade path to Spring Boot 4 / Recommendations
Hey all
We use Apache Camel 4 in Spring Boot. So far, we have kept the dependencies up to date. Latest apps are using 4.17.0. Just upgraded our template to 4.18.0 and Spring Boot 3.5.10. We use Java 21.
Based on the roadmap:
> The next 4.19 release is planned in April.
> The goal of that release is to migrate to Spring Boot v4, however all together there will be related work to be done in upcoming release to get all of this aligned.
I would like to ask for general guidance and ideas on the path to Spring Boot 4.x. I understand that with Apache Camel 4.19.0 Spring Boot 4 support will be added. How do we know individual dependencies will also work under 4.19.0 and SB 4 (especially the Camel spring-boot-starters)?
Thank you in advance.
Regards,
Arne
Freundliche Grüße / Best regards
i.A. Arne Bedürftig
Integration Architect | Integration intern EAI (EAI)
IT - Architecture & Integration (AI)
CITTI Handelsgesellschaft mbH & Co. KG
Mühlendamm 1 | 24113 Kiel | Deutschland
Mobil: +49 151 65793604
www.citti.de<http://www.citti.de/> | www.chefsculinar.de<http://www.chefsculinar.de/> | www.chefsculinar.com<http://www.chefsculinar.com/>
Kommanditgesellschaft: Amtsgericht Kiel HRA 858 KI | Komplementär: CITTI Verwaltungsgesellschaft mbH
Amtsgericht Kiel HRB 4417 | Gerichtstand: Kiel
Geschäftsführer: Gerhard Lütje, Dirk Lütje, Christoph Langness, Dr. Frank Scholz
------------------------------------------------------------------------------
Informationen (einschließlich Pflichtangaben und Datenschutzerklärungen) zu einzelnen, innerhalb der EU tätigen Gesellschaften und Zweigniederlassungen der CITTI-Gruppe finden Sie unter http://www.citti.de/html/pflichtangaben.html. Diese E-Mail enthält vertrauliche und/ oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist nicht gestattet.
Please refer to http://www.citti.de/html/pflichtangaben.html for information (including mandatory corporate particulars and data protection declarations) on selected CITTI branches and group companies registered or incorporated in the European Union. This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.
------------------------------------------------------------------------------
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Claus Ibsen <cl...@gmail.com>.
Hi Jason
That is good news, thanks for sharing that your team found a solution for
this issue.
On Wed, Mar 4, 2026 at 3:48 PM Jason Jackson <ja...@itechag.com>
wrote:
> To update everyone one this issue
>
> We were able to determine the placing application was adding MIME data to
> the beginning of the binary data and placing a wrapper around it.
>
> We corrected this and the data comes across correctly now.
>
>
> Jason
>
> ________________________________
> From: Jason Jackson <ja...@itechag.com>
> Sent: Sunday, March 1, 2026 8:03 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> Thanks for responding so quickly.
>
> The sending application is an appliance, and I have that group validating
> how data is being sent along with what connection options and settings are
> used. The connection from the appliance to ActiveMQ is performed using the
> AMPQ protocol. The data is suppose to be in binary format when it is
> placed onto the ActiveMQ queue.
>
> Are you stating that jmsMessageType=Bytes is only valid when data is
> placed onto a queue not when read?
>
> Are there any specific trace settings I should set/enable or just trace
> everything?
>
>
> Jason
>
> ________________________________
> From: Claus Ibsen <cl...@gmail.com>
> Sent: Saturday, February 28, 2026 11:35 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> CAUTION: This email originated from outside of the organization. Do not
> click links or open attachments unless you recognize the sender and know
> the content is safe.
>
>
> [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> important at https://aka.ms/LearnAboutSenderIdentification ]
>
> Hi
>
> When you set jmsMessageType=Bytes then are you sure the sender is sending
> the data to the ActiveMQ as byte data?
> This option is in fact only for when YOU send messages from Camel to the
> broker. Not when you RECEIVE.
>
> You can turn on TRACE logging on org.apache.camel.component.jms
> Then Camel will log what kind of JMS message it detected from the broker,
> such as
>
> LOG.trace("Extracting body as a TextMessage from JMS message: {}",
> message);
>
>
>
> On Sat, Feb 28, 2026 at 4:56 PM Jason Jackson <ja...@itechag.com>
> wrote:
>
> > I should have provided that and was not thinking.
> >
> > I am using the Camel version that is embedded with ActiveMQ 6.2.1 which
> is
> > 4.14.4
> >
> >
> > Jason
> >
> >
> > ________________________________
> > From: Claus Ibsen <cl...@gmail.com>
> > Sent: Saturday, February 28, 2026 10:49 AM
> > To: users@camel.apache.org <us...@camel.apache.org>
> > Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
> >
> > CAUTION: This email originated from outside of the organization. Do not
> > click links or open attachments unless you recognize the sender and know
> > the content is safe.
> >
> >
> > [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> > important at https://aka.ms/LearnAboutSenderIdentification ]
> >
> > Hi
> >
> > What version of Apache Camel are you using?
> >
> > On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <jason.jackson@itechag.com
> >
> > wrote:
> >
> > > I am receiving data within ActiveMQ on QUEUE_1, the data that arrives
> on
> > > the queue is in a raw binary format. The data is being retrieved from
> > > ActiveMQ using a Camel route and transmitted to an alternate location
> > using
> > > SFTP. If the data is modified in any way the destination location will
> > > reject the data. When the Data is retrieved from ActiveMQ and sent via
> > > SFTP there is a slight files size difference and data does not appear
> to
> > be
> > > in the exact format.
> > >
> > > After my initial testing I discovered I was possibly missing one
> setting
> > > on the from uri line, I added jmsMessageType=Bytes to force JMS to know
> > the
> > > file is in binary format.
> > >
> > > My example Camel rout I am using is below.
> > >
> > > <beans
> > > xmlns="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934771971412%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=bbChESbFimpaLLG8sgSrQxVcYXBH%2F2T60c4lnIr%2FBjM%3D&reserved=0
> <http://www.springframework.org/schema/beans>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772006861%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=f%2BeVU14Re%2FKLs%2Bn43bsNPxvFsq8xvcQrVhn3gbU1pf8%3D&reserved=0
> <http://www.springframework.org/schema/beans>>"
> > > xmlns:xsi="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772030730%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=R%2F6U4tYnRjFSH5mntu%2F3AL6%2B2yQj7VvXWJysjdOJdxs%3D&reserved=0
> <http://www.w3.org/2001/XMLSchema-instance>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772052492%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=N2c5A5PoRrAfpB9xgoYiVHevRKkK8zHrLqt50GrrVpI%3D&reserved=0
> <http://www.w3.org/2001/XMLSchema-instance>>"
> > > xsi:schemaLocation="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772071607%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dsVURP2A0KlrXxkRNLewy3gziduM66DdXxrB%2FmNOa2E%3D&reserved=0
> <http://camel.apache.org/schema/spring>
> > >
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772089763%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=3DoWA5d2u21rvotUidUXumgVBf8pb1ZyWON9KMH015M%3D&reserved=0
> <http://camel.apache.org/schema/spring/camel-spring.xsd>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772108387%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xDQUKzvUBGVOzbvcmVinDbvvYrlXEflQ41vdXfSs9Qs%3D&reserved=0
> <http://camel.apache.org/schema/spring/camel-spring.xsd>>
> > >
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772126560%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dDH8ztn%2FwWhhBySet%2BHR%2FeR1VP7tP5lL5Nnyg7875iE%3D&reserved=0
> <http://www.springframework.org/schema/beans>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772143724%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=GeCJKKRMiN2Ul0X%2Bge6f9vllCfvGC0RJdXLoeR1xvRw%3D&reserved=0
> <http://www.springframework.org/schema/beans>>
> > >
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772157586%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=PCXm4nFz9AB3GIPReExBkxS59mBdL%2F1u3KbaK669iZk%3D&reserved=0
> <http://www.springframework.org/schema/beans/spring-beans.xsd>
> > "><
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772171143%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=P7vQGWaix5%2Bevz9JDVNPh2%2FkqrAWJ7mpmc34eRNHKiw%3D&reserved=0
> >
> > >
> > > <camelContext id="camel" xmlns="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772189357%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=yxITPcSZ3JNxXef7J0nl7CVxunG8I4NB8l9FGeMI0X4%3D&reserved=0
> <http://camel.apache.org/schema/spring>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772204709%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xciZNHBhNRGc0JBFqOZkbJs58W2kO3gZ4XkNJgmv99c%3D&reserved=0
> <http://camel.apache.org/schema/spring>>"
> > > streamCache="true">
> > > <route id="QUEUE_1">
> > > <from
> > >
> >
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> > > <setProperty name="sftpFileName">
> > > <simple>${header.JMSCorrelationID}</simple>
> > > </setProperty>
> > > <!--
> > > <convertBodyTo type="java.io.InputStream"/>
> > > <convertBodyTo type="byte[]"/>
> > > <convertBodyTo type="java.lang.Byte[]"/>
> > > -->
> > > <to uri="sftp://user@ip
> > >
> >
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> > > </route>
> > > </camelContext>
> > > </beans>
> > >
> > >
> > > I am not sure if any additional transformations or settings are
> required
> > > in or to retrieve the file from ActiveMQ and send it via SFTP in pure
> raw
> > > binary format.
> > >
> > > I attempted to set/use the lines that are commented out but receive
> > > additional errors in my log file, those errors are below.
> > >
> > >
> > > Caused by: org.apache.camel.InvalidPayloadException: No body available
> of
> > > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > > Message[ID:broker_1]. Caused by: No type converter available to convert
> > > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > > Exchange[]. Caused by:
> > [org.apache.camel.NoTypeConversionAvailableException
> > > - No type converter available to convert from type: java.lang.Byte[] to
> > the
> > > required type: java.io.InputStream]
> > >
> > > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > > converter available to convert from type: java.lang.Byte[] to the
> > required
> > > type: java.io.InputStream
> > >
> > > Execution of JMS message listener failed. Caused by:
> > > [org.apache.camel.component.file.GenericFileOperationFailedException -
> > > Cannot store file: dir/file.name] |
> > > org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> > > thread #2 - JmsConsumer[QUEUE_1]
> > >
> > > Caused by: org.apache.camel.InvalidPayloadException: No body available
> of
> > > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > > Message[ID:broker_1]. Caused by: No type converter available to convert
> > > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > > Exchange[]. Caused by:
> > [org.apache.camel.NoTypeConversionAvailableException
> > > - No type converter available to convert from type: java.lang.Byte[] to
> > the
> > > required type: java.io.InputStream]
> > >
> > > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > > converter available to convert from type: java.lang.Byte[] to the
> > required
> > > type: java.io.InputStream
> > >
> > >
> > > Does the example route above appear correct or should some additional
> > > settings/conversions be added
> > >
> > >
> > >
> > > Jason
> > >
> >
> >
> > --
> > Claus Ibsen
> >
>
>
> --
> Claus Ibsen
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Jason Jackson <ja...@itechag.com>.
To update everyone one this issue
We were able to determine the placing application was adding MIME data to the beginning of the binary data and placing a wrapper around it.
We corrected this and the data comes across correctly now.
Jason
________________________________
From: Jason Jackson <ja...@itechag.com>
Sent: Sunday, March 1, 2026 8:03 AM
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Thanks for responding so quickly.
The sending application is an appliance, and I have that group validating how data is being sent along with what connection options and settings are used. The connection from the appliance to ActiveMQ is performed using the AMPQ protocol. The data is suppose to be in binary format when it is placed onto the ActiveMQ queue.
Are you stating that jmsMessageType=Bytes is only valid when data is placed onto a queue not when read?
Are there any specific trace settings I should set/enable or just trace everything?
Jason
________________________________
From: Claus Ibsen <cl...@gmail.com>
Sent: Saturday, February 28, 2026 11:35 AM
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
[You don't often get email from claus.ibsen@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi
When you set jmsMessageType=Bytes then are you sure the sender is sending
the data to the ActiveMQ as byte data?
This option is in fact only for when YOU send messages from Camel to the
broker. Not when you RECEIVE.
You can turn on TRACE logging on org.apache.camel.component.jms
Then Camel will log what kind of JMS message it detected from the broker,
such as
LOG.trace("Extracting body as a TextMessage from JMS message: {}", message);
On Sat, Feb 28, 2026 at 4:56 PM Jason Jackson <ja...@itechag.com>
wrote:
> I should have provided that and was not thinking.
>
> I am using the Camel version that is embedded with ActiveMQ 6.2.1 which is
> 4.14.4
>
>
> Jason
>
>
> ________________________________
> From: Claus Ibsen <cl...@gmail.com>
> Sent: Saturday, February 28, 2026 10:49 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> CAUTION: This email originated from outside of the organization. Do not
> click links or open attachments unless you recognize the sender and know
> the content is safe.
>
>
> [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> important at https://aka.ms/LearnAboutSenderIdentification ]
>
> Hi
>
> What version of Apache Camel are you using?
>
> On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <ja...@itechag.com>
> wrote:
>
> > I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on
> > the queue is in a raw binary format. The data is being retrieved from
> > ActiveMQ using a Camel route and transmitted to an alternate location
> using
> > SFTP. If the data is modified in any way the destination location will
> > reject the data. When the Data is retrieved from ActiveMQ and sent via
> > SFTP there is a slight files size difference and data does not appear to
> be
> > in the exact format.
> >
> > After my initial testing I discovered I was possibly missing one setting
> > on the from uri line, I added jmsMessageType=Bytes to force JMS to know
> the
> > file is in binary format.
> >
> > My example Camel rout I am using is below.
> >
> > <beans
> > xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934771971412%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=bbChESbFimpaLLG8sgSrQxVcYXBH%2F2T60c4lnIr%2FBjM%3D&reserved=0<http://www.springframework.org/schema/beans>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772006861%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=f%2BeVU14Re%2FKLs%2Bn43bsNPxvFsq8xvcQrVhn3gbU1pf8%3D&reserved=0<http://www.springframework.org/schema/beans>>"
> > xmlns:xsi="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772030730%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=R%2F6U4tYnRjFSH5mntu%2F3AL6%2B2yQj7VvXWJysjdOJdxs%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772052492%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=N2c5A5PoRrAfpB9xgoYiVHevRKkK8zHrLqt50GrrVpI%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>>"
> > xsi:schemaLocation="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772071607%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dsVURP2A0KlrXxkRNLewy3gziduM66DdXxrB%2FmNOa2E%3D&reserved=0<http://camel.apache.org/schema/spring>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772089763%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=3DoWA5d2u21rvotUidUXumgVBf8pb1ZyWON9KMH015M%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772108387%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xDQUKzvUBGVOzbvcmVinDbvvYrlXEflQ41vdXfSs9Qs%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772126560%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dDH8ztn%2FwWhhBySet%2BHR%2FeR1VP7tP5lL5Nnyg7875iE%3D&reserved=0<http://www.springframework.org/schema/beans>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772143724%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=GeCJKKRMiN2Ul0X%2Bge6f9vllCfvGC0RJdXLoeR1xvRw%3D&reserved=0<http://www.springframework.org/schema/beans>>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772157586%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=PCXm4nFz9AB3GIPReExBkxS59mBdL%2F1u3KbaK669iZk%3D&reserved=0<http://www.springframework.org/schema/beans/spring-beans.xsd>
> "><https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772171143%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=P7vQGWaix5%2Bevz9JDVNPh2%2FkqrAWJ7mpmc34eRNHKiw%3D&reserved=0>
> >
> > <camelContext id="camel" xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772189357%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=yxITPcSZ3JNxXef7J0nl7CVxunG8I4NB8l9FGeMI0X4%3D&reserved=0<http://camel.apache.org/schema/spring>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772204709%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xciZNHBhNRGc0JBFqOZkbJs58W2kO3gZ4XkNJgmv99c%3D&reserved=0<http://camel.apache.org/schema/spring>>"
> > streamCache="true">
> > <route id="QUEUE_1">
> > <from
> >
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> > <setProperty name="sftpFileName">
> > <simple>${header.JMSCorrelationID}</simple>
> > </setProperty>
> > <!--
> > <convertBodyTo type="java.io.InputStream"/>
> > <convertBodyTo type="byte[]"/>
> > <convertBodyTo type="java.lang.Byte[]"/>
> > -->
> > <to uri="sftp://user@ip
> >
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> > </route>
> > </camelContext>
> > </beans>
> >
> >
> > I am not sure if any additional transformations or settings are required
> > in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw
> > binary format.
> >
> > I attempted to set/use the lines that are commented out but receive
> > additional errors in my log file, those errors are below.
> >
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> > Execution of JMS message listener failed. Caused by:
> > [org.apache.camel.component.file.GenericFileOperationFailedException -
> > Cannot store file: dir/file.name] |
> > org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> > thread #2 - JmsConsumer[QUEUE_1]
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> >
> > Does the example route above appear correct or should some additional
> > settings/conversions be added
> >
> >
> >
> > Jason
> >
>
>
> --
> Claus Ibsen
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
Yes if the body is a byte array and you have binary=true on the FTP then it
sends the data as raw bytes.
To enable TRACE logging you need to change the logging configuration in the
message broker. So it may have a log4j.properties or something similar
where this can be tweaked and then restart the broker.
Also for the stacktrace then it helps if you show the entire stacktrace and
not only the message.
On Mon, Mar 2, 2026 at 2:13 PM Jason Jackson <ja...@itechag.com>
wrote:
> Good morning
>
> I enabled tracing for Camel in my camelContext.xml file adding the
> following
>
> trace="true"
>
> I then executed a test with a message I had in another queue.
>
> The file was transmitted and displayed the binary data on the screen.
>
> I do not see any entries in my log file with LOG.trace but what I do see
> is an INFO entry when the file was received on the queue and then sent via
> SFTP and entry of the following:
>
> BodyType: byte{}
>
> Would this indicate the message/data is being retrieved and sent in binary
> format?
>
>
> Jason
>
>
>
> ________________________________
> From: Jason Jackson <ja...@itechag.com>
> Sent: Sunday, March 1, 2026 8:03 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> Thanks for responding so quickly.
>
> The sending application is an appliance, and I have that group validating
> how data is being sent along with what connection options and settings are
> used. The connection from the appliance to ActiveMQ is performed using the
> AMPQ protocol. The data is suppose to be in binary format when it is
> placed onto the ActiveMQ queue.
>
> Are you stating that jmsMessageType=Bytes is only valid when data is
> placed onto a queue not when read?
>
> Are there any specific trace settings I should set/enable or just trace
> everything?
>
>
> Jason
>
> ________________________________
> From: Claus Ibsen <cl...@gmail.com>
> Sent: Saturday, February 28, 2026 11:35 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> CAUTION: This email originated from outside of the organization. Do not
> click links or open attachments unless you recognize the sender and know
> the content is safe.
>
>
> [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> important at https://aka.ms/LearnAboutSenderIdentification ]
>
> Hi
>
> When you set jmsMessageType=Bytes then are you sure the sender is sending
> the data to the ActiveMQ as byte data?
> This option is in fact only for when YOU send messages from Camel to the
> broker. Not when you RECEIVE.
>
> You can turn on TRACE logging on org.apache.camel.component.jms
> Then Camel will log what kind of JMS message it detected from the broker,
> such as
>
> LOG.trace("Extracting body as a TextMessage from JMS message: {}",
> message);
>
>
>
> On Sat, Feb 28, 2026 at 4:56 PM Jason Jackson <ja...@itechag.com>
> wrote:
>
> > I should have provided that and was not thinking.
> >
> > I am using the Camel version that is embedded with ActiveMQ 6.2.1 which
> is
> > 4.14.4
> >
> >
> > Jason
> >
> >
> > ________________________________
> > From: Claus Ibsen <cl...@gmail.com>
> > Sent: Saturday, February 28, 2026 10:49 AM
> > To: users@camel.apache.org <us...@camel.apache.org>
> > Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
> >
> > CAUTION: This email originated from outside of the organization. Do not
> > click links or open attachments unless you recognize the sender and know
> > the content is safe.
> >
> >
> > [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> > important at https://aka.ms/LearnAboutSenderIdentification ]
> >
> > Hi
> >
> > What version of Apache Camel are you using?
> >
> > On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <jason.jackson@itechag.com
> >
> > wrote:
> >
> > > I am receiving data within ActiveMQ on QUEUE_1, the data that arrives
> on
> > > the queue is in a raw binary format. The data is being retrieved from
> > > ActiveMQ using a Camel route and transmitted to an alternate location
> > using
> > > SFTP. If the data is modified in any way the destination location will
> > > reject the data. When the Data is retrieved from ActiveMQ and sent via
> > > SFTP there is a slight files size difference and data does not appear
> to
> > be
> > > in the exact format.
> > >
> > > After my initial testing I discovered I was possibly missing one
> setting
> > > on the from uri line, I added jmsMessageType=Bytes to force JMS to know
> > the
> > > file is in binary format.
> > >
> > > My example Camel rout I am using is below.
> > >
> > > <beans
> > > xmlns="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934771971412%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=bbChESbFimpaLLG8sgSrQxVcYXBH%2F2T60c4lnIr%2FBjM%3D&reserved=0
> <http://www.springframework.org/schema/beans>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772006861%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=f%2BeVU14Re%2FKLs%2Bn43bsNPxvFsq8xvcQrVhn3gbU1pf8%3D&reserved=0
> <http://www.springframework.org/schema/beans>>"
> > > xmlns:xsi="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772030730%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=R%2F6U4tYnRjFSH5mntu%2F3AL6%2B2yQj7VvXWJysjdOJdxs%3D&reserved=0
> <http://www.w3.org/2001/XMLSchema-instance>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772052492%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=N2c5A5PoRrAfpB9xgoYiVHevRKkK8zHrLqt50GrrVpI%3D&reserved=0
> <http://www.w3.org/2001/XMLSchema-instance>>"
> > > xsi:schemaLocation="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772071607%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dsVURP2A0KlrXxkRNLewy3gziduM66DdXxrB%2FmNOa2E%3D&reserved=0
> <http://camel.apache.org/schema/spring>
> > >
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772089763%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=3DoWA5d2u21rvotUidUXumgVBf8pb1ZyWON9KMH015M%3D&reserved=0
> <http://camel.apache.org/schema/spring/camel-spring.xsd>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772108387%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xDQUKzvUBGVOzbvcmVinDbvvYrlXEflQ41vdXfSs9Qs%3D&reserved=0
> <http://camel.apache.org/schema/spring/camel-spring.xsd>>
> > >
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772126560%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dDH8ztn%2FwWhhBySet%2BHR%2FeR1VP7tP5lL5Nnyg7875iE%3D&reserved=0
> <http://www.springframework.org/schema/beans>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772143724%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=GeCJKKRMiN2Ul0X%2Bge6f9vllCfvGC0RJdXLoeR1xvRw%3D&reserved=0
> <http://www.springframework.org/schema/beans>>
> > >
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772157586%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=PCXm4nFz9AB3GIPReExBkxS59mBdL%2F1u3KbaK669iZk%3D&reserved=0
> <http://www.springframework.org/schema/beans/spring-beans.xsd>
> > "><
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772171143%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=P7vQGWaix5%2Bevz9JDVNPh2%2FkqrAWJ7mpmc34eRNHKiw%3D&reserved=0
> >
> > >
> > > <camelContext id="camel" xmlns="
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772189357%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=yxITPcSZ3JNxXef7J0nl7CVxunG8I4NB8l9FGeMI0X4%3D&reserved=0
> <http://camel.apache.org/schema/spring>
> > <
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772204709%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xciZNHBhNRGc0JBFqOZkbJs58W2kO3gZ4XkNJgmv99c%3D&reserved=0
> <http://camel.apache.org/schema/spring>>"
> > > streamCache="true">
> > > <route id="QUEUE_1">
> > > <from
> > >
> >
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> > > <setProperty name="sftpFileName">
> > > <simple>${header.JMSCorrelationID}</simple>
> > > </setProperty>
> > > <!--
> > > <convertBodyTo type="java.io.InputStream"/>
> > > <convertBodyTo type="byte[]"/>
> > > <convertBodyTo type="java.lang.Byte[]"/>
> > > -->
> > > <to uri="sftp://user@ip
> > >
> >
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> > > </route>
> > > </camelContext>
> > > </beans>
> > >
> > >
> > > I am not sure if any additional transformations or settings are
> required
> > > in or to retrieve the file from ActiveMQ and send it via SFTP in pure
> raw
> > > binary format.
> > >
> > > I attempted to set/use the lines that are commented out but receive
> > > additional errors in my log file, those errors are below.
> > >
> > >
> > > Caused by: org.apache.camel.InvalidPayloadException: No body available
> of
> > > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > > Message[ID:broker_1]. Caused by: No type converter available to convert
> > > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > > Exchange[]. Caused by:
> > [org.apache.camel.NoTypeConversionAvailableException
> > > - No type converter available to convert from type: java.lang.Byte[] to
> > the
> > > required type: java.io.InputStream]
> > >
> > > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > > converter available to convert from type: java.lang.Byte[] to the
> > required
> > > type: java.io.InputStream
> > >
> > > Execution of JMS message listener failed. Caused by:
> > > [org.apache.camel.component.file.GenericFileOperationFailedException -
> > > Cannot store file: dir/file.name] |
> > > org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> > > thread #2 - JmsConsumer[QUEUE_1]
> > >
> > > Caused by: org.apache.camel.InvalidPayloadException: No body available
> of
> > > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > > Message[ID:broker_1]. Caused by: No type converter available to convert
> > > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > > Exchange[]. Caused by:
> > [org.apache.camel.NoTypeConversionAvailableException
> > > - No type converter available to convert from type: java.lang.Byte[] to
> > the
> > > required type: java.io.InputStream]
> > >
> > > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > > converter available to convert from type: java.lang.Byte[] to the
> > required
> > > type: java.io.InputStream
> > >
> > >
> > > Does the example route above appear correct or should some additional
> > > settings/conversions be added
> > >
> > >
> > >
> > > Jason
> > >
> >
> >
> > --
> > Claus Ibsen
> >
>
>
> --
> Claus Ibsen
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Jason Jackson <ja...@itechag.com>.
Good morning
I enabled tracing for Camel in my camelContext.xml file adding the following
trace="true"
I then executed a test with a message I had in another queue.
The file was transmitted and displayed the binary data on the screen.
I do not see any entries in my log file with LOG.trace but what I do see is an INFO entry when the file was received on the queue and then sent via SFTP and entry of the following:
BodyType: byte{}
Would this indicate the message/data is being retrieved and sent in binary format?
Jason
________________________________
From: Jason Jackson <ja...@itechag.com>
Sent: Sunday, March 1, 2026 8:03 AM
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Thanks for responding so quickly.
The sending application is an appliance, and I have that group validating how data is being sent along with what connection options and settings are used. The connection from the appliance to ActiveMQ is performed using the AMPQ protocol. The data is suppose to be in binary format when it is placed onto the ActiveMQ queue.
Are you stating that jmsMessageType=Bytes is only valid when data is placed onto a queue not when read?
Are there any specific trace settings I should set/enable or just trace everything?
Jason
________________________________
From: Claus Ibsen <cl...@gmail.com>
Sent: Saturday, February 28, 2026 11:35 AM
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
[You don't often get email from claus.ibsen@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi
When you set jmsMessageType=Bytes then are you sure the sender is sending
the data to the ActiveMQ as byte data?
This option is in fact only for when YOU send messages from Camel to the
broker. Not when you RECEIVE.
You can turn on TRACE logging on org.apache.camel.component.jms
Then Camel will log what kind of JMS message it detected from the broker,
such as
LOG.trace("Extracting body as a TextMessage from JMS message: {}", message);
On Sat, Feb 28, 2026 at 4:56 PM Jason Jackson <ja...@itechag.com>
wrote:
> I should have provided that and was not thinking.
>
> I am using the Camel version that is embedded with ActiveMQ 6.2.1 which is
> 4.14.4
>
>
> Jason
>
>
> ________________________________
> From: Claus Ibsen <cl...@gmail.com>
> Sent: Saturday, February 28, 2026 10:49 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> CAUTION: This email originated from outside of the organization. Do not
> click links or open attachments unless you recognize the sender and know
> the content is safe.
>
>
> [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> important at https://aka.ms/LearnAboutSenderIdentification ]
>
> Hi
>
> What version of Apache Camel are you using?
>
> On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <ja...@itechag.com>
> wrote:
>
> > I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on
> > the queue is in a raw binary format. The data is being retrieved from
> > ActiveMQ using a Camel route and transmitted to an alternate location
> using
> > SFTP. If the data is modified in any way the destination location will
> > reject the data. When the Data is retrieved from ActiveMQ and sent via
> > SFTP there is a slight files size difference and data does not appear to
> be
> > in the exact format.
> >
> > After my initial testing I discovered I was possibly missing one setting
> > on the from uri line, I added jmsMessageType=Bytes to force JMS to know
> the
> > file is in binary format.
> >
> > My example Camel rout I am using is below.
> >
> > <beans
> > xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934771971412%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=bbChESbFimpaLLG8sgSrQxVcYXBH%2F2T60c4lnIr%2FBjM%3D&reserved=0<http://www.springframework.org/schema/beans>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772006861%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=f%2BeVU14Re%2FKLs%2Bn43bsNPxvFsq8xvcQrVhn3gbU1pf8%3D&reserved=0<http://www.springframework.org/schema/beans>>"
> > xmlns:xsi="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772030730%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=R%2F6U4tYnRjFSH5mntu%2F3AL6%2B2yQj7VvXWJysjdOJdxs%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772052492%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=N2c5A5PoRrAfpB9xgoYiVHevRKkK8zHrLqt50GrrVpI%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>>"
> > xsi:schemaLocation="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772071607%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dsVURP2A0KlrXxkRNLewy3gziduM66DdXxrB%2FmNOa2E%3D&reserved=0<http://camel.apache.org/schema/spring>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772089763%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=3DoWA5d2u21rvotUidUXumgVBf8pb1ZyWON9KMH015M%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772108387%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xDQUKzvUBGVOzbvcmVinDbvvYrlXEflQ41vdXfSs9Qs%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772126560%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dDH8ztn%2FwWhhBySet%2BHR%2FeR1VP7tP5lL5Nnyg7875iE%3D&reserved=0<http://www.springframework.org/schema/beans>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772143724%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=GeCJKKRMiN2Ul0X%2Bge6f9vllCfvGC0RJdXLoeR1xvRw%3D&reserved=0<http://www.springframework.org/schema/beans>>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772157586%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=PCXm4nFz9AB3GIPReExBkxS59mBdL%2F1u3KbaK669iZk%3D&reserved=0<http://www.springframework.org/schema/beans/spring-beans.xsd>
> "><https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772171143%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=P7vQGWaix5%2Bevz9JDVNPh2%2FkqrAWJ7mpmc34eRNHKiw%3D&reserved=0>
> >
> > <camelContext id="camel" xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772189357%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=yxITPcSZ3JNxXef7J0nl7CVxunG8I4NB8l9FGeMI0X4%3D&reserved=0<http://camel.apache.org/schema/spring>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772204709%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xciZNHBhNRGc0JBFqOZkbJs58W2kO3gZ4XkNJgmv99c%3D&reserved=0<http://camel.apache.org/schema/spring>>"
> > streamCache="true">
> > <route id="QUEUE_1">
> > <from
> >
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> > <setProperty name="sftpFileName">
> > <simple>${header.JMSCorrelationID}</simple>
> > </setProperty>
> > <!--
> > <convertBodyTo type="java.io.InputStream"/>
> > <convertBodyTo type="byte[]"/>
> > <convertBodyTo type="java.lang.Byte[]"/>
> > -->
> > <to uri="sftp://user@ip
> >
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> > </route>
> > </camelContext>
> > </beans>
> >
> >
> > I am not sure if any additional transformations or settings are required
> > in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw
> > binary format.
> >
> > I attempted to set/use the lines that are commented out but receive
> > additional errors in my log file, those errors are below.
> >
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> > Execution of JMS message listener failed. Caused by:
> > [org.apache.camel.component.file.GenericFileOperationFailedException -
> > Cannot store file: dir/file.name] |
> > org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> > thread #2 - JmsConsumer[QUEUE_1]
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> >
> > Does the example route above appear correct or should some additional
> > settings/conversions be added
> >
> >
> >
> > Jason
> >
>
>
> --
> Claus Ibsen
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Jason Jackson <ja...@itechag.com>.
Thanks for responding so quickly.
The sending application is an appliance, and I have that group validating how data is being sent along with what connection options and settings are used. The connection from the appliance to ActiveMQ is performed using the AMPQ protocol. The data is suppose to be in binary format when it is placed onto the ActiveMQ queue.
Are you stating that jmsMessageType=Bytes is only valid when data is placed onto a queue not when read?
Are there any specific trace settings I should set/enable or just trace everything?
Jason
________________________________
From: Claus Ibsen <cl...@gmail.com>
Sent: Saturday, February 28, 2026 11:35 AM
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
[You don't often get email from claus.ibsen@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi
When you set jmsMessageType=Bytes then are you sure the sender is sending
the data to the ActiveMQ as byte data?
This option is in fact only for when YOU send messages from Camel to the
broker. Not when you RECEIVE.
You can turn on TRACE logging on org.apache.camel.component.jms
Then Camel will log what kind of JMS message it detected from the broker,
such as
LOG.trace("Extracting body as a TextMessage from JMS message: {}", message);
On Sat, Feb 28, 2026 at 4:56 PM Jason Jackson <ja...@itechag.com>
wrote:
> I should have provided that and was not thinking.
>
> I am using the Camel version that is embedded with ActiveMQ 6.2.1 which is
> 4.14.4
>
>
> Jason
>
>
> ________________________________
> From: Claus Ibsen <cl...@gmail.com>
> Sent: Saturday, February 28, 2026 10:49 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> CAUTION: This email originated from outside of the organization. Do not
> click links or open attachments unless you recognize the sender and know
> the content is safe.
>
>
> [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> important at https://aka.ms/LearnAboutSenderIdentification ]
>
> Hi
>
> What version of Apache Camel are you using?
>
> On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <ja...@itechag.com>
> wrote:
>
> > I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on
> > the queue is in a raw binary format. The data is being retrieved from
> > ActiveMQ using a Camel route and transmitted to an alternate location
> using
> > SFTP. If the data is modified in any way the destination location will
> > reject the data. When the Data is retrieved from ActiveMQ and sent via
> > SFTP there is a slight files size difference and data does not appear to
> be
> > in the exact format.
> >
> > After my initial testing I discovered I was possibly missing one setting
> > on the from uri line, I added jmsMessageType=Bytes to force JMS to know
> the
> > file is in binary format.
> >
> > My example Camel rout I am using is below.
> >
> > <beans
> > xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934771971412%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=bbChESbFimpaLLG8sgSrQxVcYXBH%2F2T60c4lnIr%2FBjM%3D&reserved=0<http://www.springframework.org/schema/beans>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772006861%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=f%2BeVU14Re%2FKLs%2Bn43bsNPxvFsq8xvcQrVhn3gbU1pf8%3D&reserved=0<http://www.springframework.org/schema/beans>>"
> > xmlns:xsi="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772030730%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=R%2F6U4tYnRjFSH5mntu%2F3AL6%2B2yQj7VvXWJysjdOJdxs%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772052492%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=N2c5A5PoRrAfpB9xgoYiVHevRKkK8zHrLqt50GrrVpI%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>>"
> > xsi:schemaLocation="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772071607%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dsVURP2A0KlrXxkRNLewy3gziduM66DdXxrB%2FmNOa2E%3D&reserved=0<http://camel.apache.org/schema/spring>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772089763%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=3DoWA5d2u21rvotUidUXumgVBf8pb1ZyWON9KMH015M%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772108387%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xDQUKzvUBGVOzbvcmVinDbvvYrlXEflQ41vdXfSs9Qs%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772126560%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=dDH8ztn%2FwWhhBySet%2BHR%2FeR1VP7tP5lL5Nnyg7875iE%3D&reserved=0<http://www.springframework.org/schema/beans>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772143724%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=GeCJKKRMiN2Ul0X%2Bge6f9vllCfvGC0RJdXLoeR1xvRw%3D&reserved=0<http://www.springframework.org/schema/beans>>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772157586%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=PCXm4nFz9AB3GIPReExBkxS59mBdL%2F1u3KbaK669iZk%3D&reserved=0<http://www.springframework.org/schema/beans/spring-beans.xsd>
> "><https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772171143%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=P7vQGWaix5%2Bevz9JDVNPh2%2FkqrAWJ7mpmc34eRNHKiw%3D&reserved=0>
> >
> > <camelContext id="camel" xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772189357%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=yxITPcSZ3JNxXef7J0nl7CVxunG8I4NB8l9FGeMI0X4%3D&reserved=0<http://camel.apache.org/schema/spring>
> <https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C3a20b74aab1b4a07959308de76e7b720%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078934772204709%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C60000%7C%7C%7C&sdata=xciZNHBhNRGc0JBFqOZkbJs58W2kO3gZ4XkNJgmv99c%3D&reserved=0<http://camel.apache.org/schema/spring>>"
> > streamCache="true">
> > <route id="QUEUE_1">
> > <from
> >
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> > <setProperty name="sftpFileName">
> > <simple>${header.JMSCorrelationID}</simple>
> > </setProperty>
> > <!--
> > <convertBodyTo type="java.io.InputStream"/>
> > <convertBodyTo type="byte[]"/>
> > <convertBodyTo type="java.lang.Byte[]"/>
> > -->
> > <to uri="sftp://user@ip
> >
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> > </route>
> > </camelContext>
> > </beans>
> >
> >
> > I am not sure if any additional transformations or settings are required
> > in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw
> > binary format.
> >
> > I attempted to set/use the lines that are commented out but receive
> > additional errors in my log file, those errors are below.
> >
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> > Execution of JMS message listener failed. Caused by:
> > [org.apache.camel.component.file.GenericFileOperationFailedException -
> > Cannot store file: dir/file.name] |
> > org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> > thread #2 - JmsConsumer[QUEUE_1]
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> >
> > Does the example route above appear correct or should some additional
> > settings/conversions be added
> >
> >
> >
> > Jason
> >
>
>
> --
> Claus Ibsen
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
When you set jmsMessageType=Bytes then are you sure the sender is sending
the data to the ActiveMQ as byte data?
This option is in fact only for when YOU send messages from Camel to the
broker. Not when you RECEIVE.
You can turn on TRACE logging on org.apache.camel.component.jms
Then Camel will log what kind of JMS message it detected from the broker,
such as
LOG.trace("Extracting body as a TextMessage from JMS message: {}", message);
On Sat, Feb 28, 2026 at 4:56 PM Jason Jackson <ja...@itechag.com>
wrote:
> I should have provided that and was not thinking.
>
> I am using the Camel version that is embedded with ActiveMQ 6.2.1 which is
> 4.14.4
>
>
> Jason
>
>
> ________________________________
> From: Claus Ibsen <cl...@gmail.com>
> Sent: Saturday, February 28, 2026 10:49 AM
> To: users@camel.apache.org <us...@camel.apache.org>
> Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
>
> CAUTION: This email originated from outside of the organization. Do not
> click links or open attachments unless you recognize the sender and know
> the content is safe.
>
>
> [You don't often get email from claus.ibsen@gmail.com. Learn why this is
> important at https://aka.ms/LearnAboutSenderIdentification ]
>
> Hi
>
> What version of Apache Camel are you using?
>
> On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <ja...@itechag.com>
> wrote:
>
> > I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on
> > the queue is in a raw binary format. The data is being retrieved from
> > ActiveMQ using a Camel route and transmitted to an alternate location
> using
> > SFTP. If the data is modified in any way the destination location will
> > reject the data. When the Data is retrieved from ActiveMQ and sent via
> > SFTP there is a slight files size difference and data does not appear to
> be
> > in the exact format.
> >
> > After my initial testing I discovered I was possibly missing one setting
> > on the from uri line, I added jmsMessageType=Bytes to force JMS to know
> the
> > file is in binary format.
> >
> > My example Camel rout I am using is below.
> >
> > <beans
> > xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247675452%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=tWBljbn7OS5RrLkamSDLTsZi7wyc1mHwjUNLJBOW4Eg%3D&reserved=0
> <http://www.springframework.org/schema/beans>"
> > xmlns:xsi="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247706146%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=UCjTXrY0T5i8SHXV5wUG3mDwyWD7M%2BcXkUCVQ6UpQio%3D&reserved=0
> <http://www.w3.org/2001/XMLSchema-instance>"
> > xsi:schemaLocation="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247720314%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=ZoF9Ol9%2B0bo%2BDZGRaVXKhivgFl294mmxuBThWQIKYBU%3D&reserved=0
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247739905%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=pf%2FNaReReTFYQw0w2bf%2B3GciaR2kfTpvD%2BUWCzFHAd4%3D&reserved=0
> <http://camel.apache.org/schema/spring/camel-spring.xsd>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247755766%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=T655srDLYvEooTrJf7DZjjUjIyqI9h7mmt7tfzo9zQc%3D&reserved=0
> <http://www.springframework.org/schema/beans>
> >
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247773781%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=YabFzSlDYPwdWZxnmX3GfMbfkDPxJ031CQYYwu%2B4pSQ%3D&reserved=0
> "><http://www.springframework.org/schema/beans/spring-beans.xsd>
> >
> > <camelContext id="camel" xmlns="
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247791694%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=CtUcnmJpVj86xyBxprlMZpJbCdi%2F3vWaDNW0ovJnIZc%3D&reserved=0
> <http://camel.apache.org/schema/spring>"
> > streamCache="true">
> > <route id="QUEUE_1">
> > <from
> >
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> > <setProperty name="sftpFileName">
> > <simple>${header.JMSCorrelationID}</simple>
> > </setProperty>
> > <!--
> > <convertBodyTo type="java.io.InputStream"/>
> > <convertBodyTo type="byte[]"/>
> > <convertBodyTo type="java.lang.Byte[]"/>
> > -->
> > <to uri="sftp://user@ip
> >
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> > </route>
> > </camelContext>
> > </beans>
> >
> >
> > I am not sure if any additional transformations or settings are required
> > in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw
> > binary format.
> >
> > I attempted to set/use the lines that are commented out but receive
> > additional errors in my log file, those errors are below.
> >
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> > Execution of JMS message listener failed. Caused by:
> > [org.apache.camel.component.file.GenericFileOperationFailedException -
> > Cannot store file: dir/file.name] |
> > org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> > thread #2 - JmsConsumer[QUEUE_1]
> >
> > Caused by: org.apache.camel.InvalidPayloadException: No body available of
> > type: java.io.InputStream but has type: java.lang.Byte[] on:
> > Message[ID:broker_1]. Caused by: No type converter available to convert
> > from type: java.lang.Byte[] to the required type: java.io.InputStream.
> > Exchange[]. Caused by:
> [org.apache.camel.NoTypeConversionAvailableException
> > - No type converter available to convert from type: java.lang.Byte[] to
> the
> > required type: java.io.InputStream]
> >
> > Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> > converter available to convert from type: java.lang.Byte[] to the
> required
> > type: java.io.InputStream
> >
> >
> > Does the example route above appear correct or should some additional
> > settings/conversions be added
> >
> >
> >
> > Jason
> >
>
>
> --
> Claus Ibsen
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Jason Jackson <ja...@itechag.com>.
I should have provided that and was not thinking.
I am using the Camel version that is embedded with ActiveMQ 6.2.1 which is 4.14.4
Jason
________________________________
From: Claus Ibsen <cl...@gmail.com>
Sent: Saturday, February 28, 2026 10:49 AM
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
[You don't often get email from claus.ibsen@gmail.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hi
What version of Apache Camel are you using?
On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <ja...@itechag.com>
wrote:
> I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on
> the queue is in a raw binary format. The data is being retrieved from
> ActiveMQ using a Camel route and transmitted to an alternate location using
> SFTP. If the data is modified in any way the destination location will
> reject the data. When the Data is retrieved from ActiveMQ and sent via
> SFTP there is a slight files size difference and data does not appear to be
> in the exact format.
>
> After my initial testing I discovered I was possibly missing one setting
> on the from uri line, I added jmsMessageType=Bytes to force JMS to know the
> file is in binary format.
>
> My example Camel rout I am using is below.
>
> <beans
> xmlns="https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247675452%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=tWBljbn7OS5RrLkamSDLTsZi7wyc1mHwjUNLJBOW4Eg%3D&reserved=0<http://www.springframework.org/schema/beans>"
> xmlns:xsi="https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema-instance&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247706146%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=UCjTXrY0T5i8SHXV5wUG3mDwyWD7M%2BcXkUCVQ6UpQio%3D&reserved=0<http://www.w3.org/2001/XMLSchema-instance>"
> xsi:schemaLocation="https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247720314%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=ZoF9Ol9%2B0bo%2BDZGRaVXKhivgFl294mmxuBThWQIKYBU%3D&reserved=0
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring%2Fcamel-spring.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247739905%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=pf%2FNaReReTFYQw0w2bf%2B3GciaR2kfTpvD%2BUWCzFHAd4%3D&reserved=0<http://camel.apache.org/schema/spring/camel-spring.xsd>
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247755766%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=T655srDLYvEooTrJf7DZjjUjIyqI9h7mmt7tfzo9zQc%3D&reserved=0<http://www.springframework.org/schema/beans>
> https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.springframework.org%2Fschema%2Fbeans%2Fspring-beans.xsd&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247773781%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=YabFzSlDYPwdWZxnmX3GfMbfkDPxJ031CQYYwu%2B4pSQ%3D&reserved=0"><http://www.springframework.org/schema/beans/spring-beans.xsd>
>
> <camelContext id="camel" xmlns="https://nam12.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcamel.apache.org%2Fschema%2Fspring&data=05%7C02%7Cjason.jackson%40itechag.com%7C2c43cb13ce3043845f2008de76e113b7%7C07e5f1b9902a4d9f974c04601319bfec%7C0%7C0%7C639078906247791694%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=CtUcnmJpVj86xyBxprlMZpJbCdi%2F3vWaDNW0ovJnIZc%3D&reserved=0<http://camel.apache.org/schema/spring>"
> streamCache="true">
> <route id="QUEUE_1">
> <from
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> <setProperty name="sftpFileName">
> <simple>${header.JMSCorrelationID}</simple>
> </setProperty>
> <!--
> <convertBodyTo type="java.io.InputStream"/>
> <convertBodyTo type="byte[]"/>
> <convertBodyTo type="java.lang.Byte[]"/>
> -->
> <to uri="sftp://user@ip
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> </route>
> </camelContext>
> </beans>
>
>
> I am not sure if any additional transformations or settings are required
> in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw
> binary format.
>
> I attempted to set/use the lines that are commented out but receive
> additional errors in my log file, those errors are below.
>
>
> Caused by: org.apache.camel.InvalidPayloadException: No body available of
> type: java.io.InputStream but has type: java.lang.Byte[] on:
> Message[ID:broker_1]. Caused by: No type converter available to convert
> from type: java.lang.Byte[] to the required type: java.io.InputStream.
> Exchange[]. Caused by: [org.apache.camel.NoTypeConversionAvailableException
> - No type converter available to convert from type: java.lang.Byte[] to the
> required type: java.io.InputStream]
>
> Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> converter available to convert from type: java.lang.Byte[] to the required
> type: java.io.InputStream
>
> Execution of JMS message listener failed. Caused by:
> [org.apache.camel.component.file.GenericFileOperationFailedException -
> Cannot store file: dir/file.name] |
> org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> thread #2 - JmsConsumer[QUEUE_1]
>
> Caused by: org.apache.camel.InvalidPayloadException: No body available of
> type: java.io.InputStream but has type: java.lang.Byte[] on:
> Message[ID:broker_1]. Caused by: No type converter available to convert
> from type: java.lang.Byte[] to the required type: java.io.InputStream.
> Exchange[]. Caused by: [org.apache.camel.NoTypeConversionAvailableException
> - No type converter available to convert from type: java.lang.Byte[] to the
> required type: java.io.InputStream]
>
> Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> converter available to convert from type: java.lang.Byte[] to the required
> type: java.io.InputStream
>
>
> Does the example route above appear correct or should some additional
> settings/conversions be added
>
>
>
> Jason
>
--
Claus Ibsen
Re: Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
What version of Apache Camel are you using?
On Sat, Feb 28, 2026 at 4:33 PM Jason Jackson <ja...@itechag.com>
wrote:
> I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on
> the queue is in a raw binary format. The data is being retrieved from
> ActiveMQ using a Camel route and transmitted to an alternate location using
> SFTP. If the data is modified in any way the destination location will
> reject the data. When the Data is retrieved from ActiveMQ and sent via
> SFTP there is a slight files size difference and data does not appear to be
> in the exact format.
>
> After my initial testing I discovered I was possibly missing one setting
> on the from uri line, I added jmsMessageType=Bytes to force JMS to know the
> file is in binary format.
>
> My example Camel rout I am using is below.
>
> <beans
> xmlns="http://www.springframework.org/schema/beans"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://camel.apache.org/schema/spring
> http://camel.apache.org/schema/spring/camel-spring.xsd
> http://www.springframework.org/schema/beans
> http://www.springframework.org/schema/beans/spring-beans.xsd">
>
> <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring"
> streamCache="true">
> <route id="QUEUE_1">
> <from
> uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
> <setProperty name="sftpFileName">
> <simple>${header.JMSCorrelationID}</simple>
> </setProperty>
> <!--
> <convertBodyTo type="java.io.InputStream"/>
> <convertBodyTo type="byte[]"/>
> <convertBodyTo type="java.lang.Byte[]"/>
> -->
> <to uri="sftp://user@ip
> /dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
> </route>
> </camelContext>
> </beans>
>
>
> I am not sure if any additional transformations or settings are required
> in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw
> binary format.
>
> I attempted to set/use the lines that are commented out but receive
> additional errors in my log file, those errors are below.
>
>
> Caused by: org.apache.camel.InvalidPayloadException: No body available of
> type: java.io.InputStream but has type: java.lang.Byte[] on:
> Message[ID:broker_1]. Caused by: No type converter available to convert
> from type: java.lang.Byte[] to the required type: java.io.InputStream.
> Exchange[]. Caused by: [org.apache.camel.NoTypeConversionAvailableException
> - No type converter available to convert from type: java.lang.Byte[] to the
> required type: java.io.InputStream]
>
> Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> converter available to convert from type: java.lang.Byte[] to the required
> type: java.io.InputStream
>
> Execution of JMS message listener failed. Caused by:
> [org.apache.camel.component.file.GenericFileOperationFailedException -
> Cannot store file: dir/file.name] |
> org.apache.camel.component.jms.EndpointMessageListener | Camel (camel)
> thread #2 - JmsConsumer[QUEUE_1]
>
> Caused by: org.apache.camel.InvalidPayloadException: No body available of
> type: java.io.InputStream but has type: java.lang.Byte[] on:
> Message[ID:broker_1]. Caused by: No type converter available to convert
> from type: java.lang.Byte[] to the required type: java.io.InputStream.
> Exchange[]. Caused by: [org.apache.camel.NoTypeConversionAvailableException
> - No type converter available to convert from type: java.lang.Byte[] to the
> required type: java.io.InputStream]
>
> Caused by: org.apache.camel.NoTypeConversionAvailableException: No type
> converter available to convert from type: java.lang.Byte[] to the required
> type: java.io.InputStream
>
>
> Does the example route above appear correct or should some additional
> settings/conversions be added
>
>
>
> Jason
>
--
Claus Ibsen
Camel and ActiveMQ SFTP Data Transfers in Raw Binary Format
Posted by Jason Jackson <ja...@itechag.com>.
I am receiving data within ActiveMQ on QUEUE_1, the data that arrives on the queue is in a raw binary format. The data is being retrieved from ActiveMQ using a Camel route and transmitted to an alternate location using SFTP. If the data is modified in any way the destination location will reject the data. When the Data is retrieved from ActiveMQ and sent via SFTP there is a slight files size difference and data does not appear to be in the exact format.
After my initial testing I discovered I was possibly missing one setting on the from uri line, I added jmsMessageType=Bytes to force JMS to know the file is in binary format.
My example Camel rout I am using is below.
<beans
xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
<camelContext id="camel" xmlns="http://camel.apache.org/schema/spring" streamCache="true">
<route id="QUEUE_1">
<from uri="jms:queue://QUEUE_1?jmsMessageType=Bytes&cacheLevelName=CACHE_CONSUMER&concurrentConsumers=4&maxConcurrentConsumers=10&maxMessagesPerTask=200&transacted=true&lazyCreateTransactionManager=false&acknowledgementModeName=CLIENT_ACKNOWLEDGE&connectionFactory=#broker1"/>
<setProperty name="sftpFileName">
<simple>${header.JMSCorrelationID}</simple>
</setProperty>
<!--
<convertBodyTo type="java.io.InputStream"/>
<convertBodyTo type="byte[]"/>
<convertBodyTo type="java.lang.Byte[]"/>
-->
<to uri="sftp://user@ip/dir?password=myPassword&autoCreate=true&binary=true&passiveMode=true&knownHostsFile=/dir/hosts&fileName=${exchangeProperty.sftpFileName}"/>
</route>
</camelContext>
</beans>
I am not sure if any additional transformations or settings are required in or to retrieve the file from ActiveMQ and send it via SFTP in pure raw binary format.
I attempted to set/use the lines that are commented out but receive additional errors in my log file, those errors are below.
Caused by: org.apache.camel.InvalidPayloadException: No body available of type: java.io.InputStream but has type: java.lang.Byte[] on: Message[ID:broker_1]. Caused by: No type converter available to convert from type: java.lang.Byte[] to the required type: java.io.InputStream. Exchange[]. Caused by: [org.apache.camel.NoTypeConversionAvailableException - No type converter available to convert from type: java.lang.Byte[] to the required type: java.io.InputStream]
Caused by: org.apache.camel.NoTypeConversionAvailableException: No type converter available to convert from type: java.lang.Byte[] to the required type: java.io.InputStream
Execution of JMS message listener failed. Caused by: [org.apache.camel.component.file.GenericFileOperationFailedException - Cannot store file: dir/file.name] | org.apache.camel.component.jms.EndpointMessageListener | Camel (camel) thread #2 - JmsConsumer[QUEUE_1]
Caused by: org.apache.camel.InvalidPayloadException: No body available of type: java.io.InputStream but has type: java.lang.Byte[] on: Message[ID:broker_1]. Caused by: No type converter available to convert from type: java.lang.Byte[] to the required type: java.io.InputStream. Exchange[]. Caused by: [org.apache.camel.NoTypeConversionAvailableException - No type converter available to convert from type: java.lang.Byte[] to the required type: java.io.InputStream]
Caused by: org.apache.camel.NoTypeConversionAvailableException: No type converter available to convert from type: java.lang.Byte[] to the required type: java.io.InputStream
Does the example route above appear correct or should some additional settings/conversions be added
Jason
AW: Re: Upgrade path to Spring Boot 4 / Recommendations
Posted by "Bed�rftig, Arne via users" <us...@camel.apache.org>.
Hello Federico
Thank you so much for your response and the resources. I will monitor them closely and then simply give it a try in April.
Freundliche Grüße / Best regards
i.A. Arne Bedürftig
Integration Architect | Integration intern EAI (EAI)
IT - Architecture & Integration (AI)
CITTI Handelsgesellschaft mbH & Co. KG
Mühlendamm 1 | 24113 Kiel | Deutschland
Mobil: +49 151 65793604
www.citti.de<http://www.citti.de/> | www.chefsculinar.de<http://www.chefsculinar.de/> | www.chefsculinar.com<http://www.chefsculinar.com/>
Kommanditgesellschaft: Amtsgericht Kiel HRA 858 KI | Komplementär: CITTI Verwaltungsgesellschaft mbH
Amtsgericht Kiel HRB 4417 | Gerichtstand: Kiel
Geschäftsführer: Gerhard Lütje, Dirk Lütje, Christoph Langness, Dr. Frank Scholz
Von: Federico Mariani <fe...@gmail.com>
Datum: Freitag, 27. Februar 2026 um 11:38
An: users@camel.apache.org <us...@camel.apache.org>
Betreff: [users-return-75896-Arne.Beduerftig=citti.de@camel.apache.org] Re: Upgrade path to Spring Boot 4 / Recommendations
Hello,
I've updated the camel-spring-boot-examples
<https://github.com/apache/camel-spring-boot-examples/> repository to use
Camel 4.19.0-SNAPSHOT and Spring Boot 4 and the experience was not bad, this
is the commit
<https://github.com/apache/camel-spring-boot-examples/commit/102730d75f53dd61606ef8e5812e0722eeec79ba>
and
as you can see all the examples are still supported and working fine. The
actual work will be on Spring Boot 4 upgrade:
- junit5 -> 6
- *camel-test-spring-junit5* -> *camel-test-spring-junit6 *with some
package updates
- some dependencies need to be updated like *spring-boot-starter-web* ->
*spring-boot-starter-webmvc*
- jackson3 (packages updates mostly).
I've used the Spring Boot 4 OpenRewrite recipe to update the examples, and
it did most of the work automatically.
I thought it was harder than expected.
You can monitor the Camel 4.19 upgrade guide
<https://github.com/apache/camel/blob/4ca46d5ceae626df0f3e4c908faebd4b80f8dc23/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_19.adoc>
we'll
include components removal and potential issues as we find them. Right now
you can already generate a new Camel Spring Boot application using the
archetype and it works as expected *mvn archetype:generate
-DarchetypeGroupId=org.apache.camel.archetypes
-DarchetypeArtifactId=camel-archetype-spring-boot
-DarchetypeVersion=4.19.0-SNAPSHOT -DgroupId=com.test -DartifactId=test
-Dversion=1.0-SNAPSHOT*
Greetings,
Federico
Il giorno ven 27 feb 2026 alle ore 11:24 Bedürftig, Arne via users <
users@camel.apache.org> ha scritto:
> Hey all
>
> We use Apache Camel 4 in Spring Boot. So far, we have kept the
> dependencies up to date. Latest apps are using 4.17.0. Just upgraded our
> template to 4.18.0 and Spring Boot 3.5.10. We use Java 21.
>
> Based on the roadmap:
>
> > The next 4.19 release is planned in April.
> > The goal of that release is to migrate to Spring Boot v4, however all
> together there will be related work to be done in upcoming release to get
> all of this aligned.
>
> I would like to ask for general guidance and ideas on the path to Spring
> Boot 4.x. I understand that with Apache Camel 4.19.0 Spring Boot 4 support
> will be added. How do we know individual dependencies will also work under
> 4.19.0 and SB 4 (especially the Camel spring-boot-starters)?
>
> Thank you in advance.
>
> Regards,
> Arne
>
>
> Freundliche Grüße / Best regards
>
>
>
> i.A. Arne Bedürftig
>
> Integration Architect | Integration intern EAI (EAI)
>
> IT - Architecture & Integration (AI)
>
>
>
> CITTI Handelsgesellschaft mbH & Co. KG
>
> Mühlendamm 1 | 24113 Kiel | Deutschland
>
> Mobil: +49 151 65793604
>
> www.citti.de<http://www.citti.de/> | www.chefsculinar.de<<http://www.chefsculinar.de<>
> http://www.chefsculinar.de/> | www.chefsculinar.com<<http://www.chefsculinar.com<>
> http://www.chefsculinar.com/>
>
>
>
> Kommanditgesellschaft: Amtsgericht Kiel HRA 858 KI | Komplementär: CITTI
> Verwaltungsgesellschaft mbH
>
> Amtsgericht Kiel HRB 4417 | Gerichtstand: Kiel
>
> Geschäftsführer: Gerhard Lütje, Dirk Lütje, Christoph Langness, Dr. Frank
> Scholz
>
> ------------------------------------------------------------------------------
> Informationen (einschließlich Pflichtangaben und Datenschutzerklärungen)
> zu einzelnen, innerhalb der EU tätigen Gesellschaften und
> Zweigniederlassungen der CITTI-Gruppe finden Sie unter
> http://www.citti.de/html/pflichtangaben.html. Diese E-Mail enthält
> vertrauliche und/ oder rechtlich geschützte Informationen. Wenn Sie nicht
> der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben,
> informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail.
> Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist
> nicht gestattet.
>
> Please refer to http://www.citti.de/html/pflichtangaben.html for
> information (including mandatory corporate particulars and data protection
> declarations) on selected CITTI branches and group companies registered or
> incorporated in the European Union. This e-mail may contain confidential
> and/or privileged information. If you are not the intended recipient (or
> have received this e-mail in error) please notify the sender immediately
> and delete this e-mail. Any unauthorized copying, disclosure or
> distribution of the material in this e-mail is strictly forbidden.
>
> ------------------------------------------------------------------------------
>
------------------------------------------------------------------------------
Informationen (einschließlich Pflichtangaben und Datenschutzerklärungen) zu einzelnen, innerhalb der EU tätigen Gesellschaften und Zweigniederlassungen der CITTI-Gruppe finden Sie unter http://www.citti.de/html/pflichtangaben.html. Diese E-Mail enthält vertrauliche und/ oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist nicht gestattet.
Please refer to http://www.citti.de/html/pflichtangaben.html for information (including mandatory corporate particulars and data protection declarations) on selected CITTI branches and group companies registered or incorporated in the European Union. This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.
------------------------------------------------------------------------------
Re: Upgrade path to Spring Boot 4 / Recommendations
Posted by Federico Mariani <fe...@gmail.com>.
Hello,
I've updated the camel-spring-boot-examples
<https://github.com/apache/camel-spring-boot-examples/> repository to use
Camel 4.19.0-SNAPSHOT and Spring Boot 4 and the experience was not bad, this
is the commit
<https://github.com/apache/camel-spring-boot-examples/commit/102730d75f53dd61606ef8e5812e0722eeec79ba>
and
as you can see all the examples are still supported and working fine. The
actual work will be on Spring Boot 4 upgrade:
- junit5 -> 6
- *camel-test-spring-junit5* -> *camel-test-spring-junit6 *with some
package updates
- some dependencies need to be updated like *spring-boot-starter-web* ->
*spring-boot-starter-webmvc*
- jackson3 (packages updates mostly).
I've used the Spring Boot 4 OpenRewrite recipe to update the examples, and
it did most of the work automatically.
I thought it was harder than expected.
You can monitor the Camel 4.19 upgrade guide
<https://github.com/apache/camel/blob/4ca46d5ceae626df0f3e4c908faebd4b80f8dc23/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_19.adoc>
we'll
include components removal and potential issues as we find them. Right now
you can already generate a new Camel Spring Boot application using the
archetype and it works as expected *mvn archetype:generate
-DarchetypeGroupId=org.apache.camel.archetypes
-DarchetypeArtifactId=camel-archetype-spring-boot
-DarchetypeVersion=4.19.0-SNAPSHOT -DgroupId=com.test -DartifactId=test
-Dversion=1.0-SNAPSHOT*
Greetings,
Federico
Il giorno ven 27 feb 2026 alle ore 11:24 Bedürftig, Arne via users <
users@camel.apache.org> ha scritto:
> Hey all
>
> We use Apache Camel 4 in Spring Boot. So far, we have kept the
> dependencies up to date. Latest apps are using 4.17.0. Just upgraded our
> template to 4.18.0 and Spring Boot 3.5.10. We use Java 21.
>
> Based on the roadmap:
>
> > The next 4.19 release is planned in April.
> > The goal of that release is to migrate to Spring Boot v4, however all
> together there will be related work to be done in upcoming release to get
> all of this aligned.
>
> I would like to ask for general guidance and ideas on the path to Spring
> Boot 4.x. I understand that with Apache Camel 4.19.0 Spring Boot 4 support
> will be added. How do we know individual dependencies will also work under
> 4.19.0 and SB 4 (especially the Camel spring-boot-starters)?
>
> Thank you in advance.
>
> Regards,
> Arne
>
>
> Freundliche Grüße / Best regards
>
>
>
> i.A. Arne Bedürftig
>
> Integration Architect | Integration intern EAI (EAI)
>
> IT - Architecture & Integration (AI)
>
>
>
> CITTI Handelsgesellschaft mbH & Co. KG
>
> Mühlendamm 1 | 24113 Kiel | Deutschland
>
> Mobil: +49 151 65793604
>
> www.citti.de<http://www.citti.de/> | www.chefsculinar.de<
> http://www.chefsculinar.de/> | www.chefsculinar.com<
> http://www.chefsculinar.com/>
>
>
>
> Kommanditgesellschaft: Amtsgericht Kiel HRA 858 KI | Komplementär: CITTI
> Verwaltungsgesellschaft mbH
>
> Amtsgericht Kiel HRB 4417 | Gerichtstand: Kiel
>
> Geschäftsführer: Gerhard Lütje, Dirk Lütje, Christoph Langness, Dr. Frank
> Scholz
>
> ------------------------------------------------------------------------------
> Informationen (einschließlich Pflichtangaben und Datenschutzerklärungen)
> zu einzelnen, innerhalb der EU tätigen Gesellschaften und
> Zweigniederlassungen der CITTI-Gruppe finden Sie unter
> http://www.citti.de/html/pflichtangaben.html. Diese E-Mail enthält
> vertrauliche und/ oder rechtlich geschützte Informationen. Wenn Sie nicht
> der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben,
> informieren Sie bitte sofort den Absender und vernichten Sie diese E-Mail.
> Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist
> nicht gestattet.
>
> Please refer to http://www.citti.de/html/pflichtangaben.html for
> information (including mandatory corporate particulars and data protection
> declarations) on selected CITTI branches and group companies registered or
> incorporated in the European Union. This e-mail may contain confidential
> and/or privileged information. If you are not the intended recipient (or
> have received this e-mail in error) please notify the sender immediately
> and delete this e-mail. Any unauthorized copying, disclosure or
> distribution of the material in this e-mail is strictly forbidden.
>
> ------------------------------------------------------------------------------
>