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

Improve ProducerTemplate documentation and code examples using ProducerTemplate

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Won't Fix
    • 3.7.0
    • None
    • documentation
    • None
    • Unknown

    Description

      I'm currently reading about error handling in Camel, specifically Using a Processor as a failure handler.

      The code example lists

      Code Example
      // send it to our mock endpoint
      exchange.getContext().createProducerTemplate().send("mock:myerror", exchange);
      

      According to the Javadoc of createProducerTemplate() and ProducerTemplate this is problematic:

      Since we're all lazy devs, we tend to copy paste code listings and think we're done.

      I suggest the following:

      Attachments

        Activity

          People

            Unassigned Unassigned
            thokuest Thomas K├╝stermann
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: