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

ModelCamelContext.setTracing(true) makes Camel Salesforce APEX calls fragile

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Not A Problem
    • Affects Version/s: 2.23.1
    • Fix Version/s: None
    • Component/s: camel-salesforce
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      We were having an issue with a process hanging on Salesforce APEX REST calls. It turns out that the key factor was whether or not tracing was enabled.

      It isn't clear to me as to what the correct fix is, but this code change works around the problem:

      — a/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/internal/processor/JsonRestProcessor.java
      +++ b/components/camel-salesforce/camel-salesforce-component/src/main/java/org/apache/camel/component/salesforce/internal/processor/JsonRestProcessor.java
      @@ -188,6 +188,7 @@ public class JsonRestProcessor extends AbstractRestProcessor {
      // if an exception is reported we should not loose it
      if (shouldReport(ex))

      Unknown macro: { exchange.setException(ex); + out.setBody(""); }

      } else if (responseEntity != null) {
      // do we need to un-marshal a response

      All of the cases of it hanging were when there were exceptions thrown by the service.

      Basically if the body of the out message is set, then it doesn't hang. I can provide more details if need be as well.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jsightle@redhat.com Jesse Sightler
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: