Uploaded image for project: 'Red Hat Fuse'
  1. Red Hat Fuse
  2. ENTESB-16812

camel stream cache data loss issue

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • fuse-7.9-GA
    • fuse-7.8-GA
    • Camel
    • None
    • False
    • False
    • % %
    • Todo
    • Undefined
    • Hide

      Reproducer attached. test  'mvn  camel:run' 

      Show
      Reproducer attached. test  'mvn  camel:run' 

    Description

      complete data is not coming in consumer route 

       

      // <streamCaching id="myCacheConfig" bufferSize="4194304" spoolDirectory="/tmp/cachedir" spoolThreshold="65536"/>
      
      <route>
      <from uri="file:src/data?noop=true" />
      <log message=" $simple{in.header.CamelFileName}" />
      <log id="ftplog1"
      message="file Consumed '${headers[CamelFileName]}': '${headers[Exchange.FILE_LAST_MODIFIED]}'  " />
      <convertBodyTo type="String" />
      <log message="===after converting is : ${body.length}" />
      <to uri="activemq:queue:outputQueue?jmsMessageType=Stream" />
      <log message="===Producer activemq route size : ${body.length}" />
      
      </route>
      <route>
      <from uri="activemq:queue:outputQueue" />
      <log message="==consumer activemq route body size : ${body.length}" />
      <log message="=== message type is :${body.class.name}" />
      <log
      message="===this is exchange.headers in _message-handling-receive-msg: ${headers}" />
      <log
      message="===this is exchange.properties in _message-handling-receive-msg: ${exchange.properties}" />
      
      </route>
      

      logs:

      // [s) thread #2 - file://src/data] route1                         INFO   message1.txt
      [s) thread #2 - file://src/data] route1                         INFO  file Consumed 'message1.txt': ''  
      [s) thread #2 - file://src/data] route1                         INFO  ===after converting is : 4194304
      [               ActiveMQ Task-1] FailoverTransport              INFO  Successfully connected to tcp://localhost:61616
      [s) thread #2 - file://src/data] route1                         INFO  ===Producer activemq route size : 4194304
      [ #3 - JmsConsumer[outputQueue]] route2                         INFO  ==consumer activemq route body size : 131072
      [ #3 - JmsConsumer[outputQueue]] route2                         INFO  === message type is :org.apache.camel.converter.stream.InputStreamCache
      
      consumer route is not getting complete data, and i see '/tmp/cachedir' empty. what is wrong in above configuration
      
      
      

      Attachments

        Activity

          People

            yfang@redhat.com Freeman(Yue) Fang
            rhn-support-kkakarla kodandaRamu kakarla
            Federico Mariani Federico Mariani
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: