Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-6448

Incorrect documentation for XML redeliveryPolicyRef in OnException clause

    XMLWordPrintableJSON

Details

    • Novice

    Description

      The example in the documentation on the onException page (http://camel.apache.org/exception-clause.html) shows incorrect configuration of an external redelivery policy.

      It currently shows:

      <bean id="myRedeliveryPolicy" class="org.apache.camel.processor.RedeliveryPolicy">
      <property name="maximumRedeliveries" value="${myprop.max}"/>
      </bean>

      <onException>
      <!-- you can define multiple exceptions just adding more exception elements as show below -->
      <exception>com.mycompany.MyFirstException</exception>
      <exception>com.mycompany.MySecondException</exception>

      <!-- here we reference our redelivery policy defined above -->
      <redeliveryPolicy ref="myRedeliveryPolicy"/>
      </onException>

      But it should be:

      <bean id="myRedeliveryPolicy" class="org.apache.camel.processor.RedeliveryPolicy">
      <property name="maximumRedeliveries" value="${myprop.max}"/>
      </bean>

      <onException redeliveryPolicyRef="myRedeliveryPolicy">
      <exception>com.mycompany.MyFirstException</exception>
      <exception>com.mycompany.MySecondException</exception>
      <!-- more config here -->
      </onException>

      Attachments

        Activity

          People

            muellerc Christian Müller
            bkiefer Ben Kiefer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: