0
votes

Facts:
1] Camel Spring Boot version 2.19.0
2] Attempt for Camel XML DSL Rest

Problem Statement : As per given example I moved my Camel context to a separate folder called "camel" under main/resources folder of Spring Boot project. However upon invocation it throws Unmarshall Exception CamelSpringBootInitializationException unexpected element

I removed them and added to another folder then none of the routes got detected !! http://www.springframework.org/schema/beans/spring-beans.xsd
http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd">

<camel:camelContext id="chCoolCamelContext" xmlns="http://camel.apache.org/schema/spring">
    <restConfiguration  bindingMode="auto" component="restlet" port="9091" />

    <rest path="/chcool">
        <get uri="pipeRequestXN2">
            <to uri="direct-vm:getNewYearDiscount" />
        </get>
    </rest>

    <route id="assocDisc-RequestRoute">
        <from uri="direct-vm:getNewYearDiscount" />
        <process ref="newYearDiscReqProcessor"></process>
    </route>
</camel:camelContext>

<bean id="newYearDiscReqProcessor" class="com.wm.mad.disc.camel.processor"></bean>

Any help in the matter? How to add them so that it is automatically detected by Boot. I need to use XML DSL as the rest of the routes are existing applications.

1

1 Answers

2
votes

It may been a bug in that Camel 2.19.x version so XML route are not automatic loaded. Try upgrade to latest release of either 2.19.x or 2.20.x.