camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Darren Davison (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CAMEL-1271) Can only interact with servicemix-http if logging is at DEBUG
Date Mon, 19 Jan 2009 09:22:59 GMT

    [ https://issues.apache.org/activemq/browse/CAMEL-1271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=48802#action_48802
] 

Darren Davison commented on CAMEL-1271:
---------------------------------------

sorry, I should have mentioned.. we're using Camel 1.5.0.  As we needed unrelated fixes made
since 1.4, we re-packaged the servicemix-camel SU to use 1.5.  So I guess this should work
but still doesn't.

We had already tried several variants of the streamCaching() DSL snippet to no avail anyway.
 Here are the results with the 2 you mentioned:

{code}from("activemq:queue.testJms.in")
  .streamCaching()
  .to("jbi:service:urn:oms:testHttp?mep=in-out")
  .to("activemq:queue.testJms.out"); {code}

in the above change, no excpetions or log messages  from servicemix.  The target webservice
is called and responds correctly.  The .in queue shows messages enqueued and dequeued correctly,
the .out queue is empty (no message ever appears on it).  With this change, we simply lose
our response messages completely and without apparent warning.


{code}streamCaching();
from("activemq:queue.testJms.in")
  .to("jbi:service:urn:oms:testHttp?mep=in-out")
  .to("activemq:queue.testJms.out"); {code}

with this change, I see exactly the same results as above.

So even with Camel 1.5, the explicit streamCaching() *does* appear to cause different behaviour.
 But it looks worse to me :(

I'm not convinced by the unit tests in this instance since they don't involve HTTP connections
that are likely to be closed before the StreamSource that wraps them has been read.  I may
be wrong though.


<joke>
Should I turn the logging up to see what's happening? :)
</joke>


> Can only interact with servicemix-http if logging is at DEBUG
> -------------------------------------------------------------
>
>                 Key: CAMEL-1271
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1271
>             Project: Apache Camel
>          Issue Type: Bug
>    Affects Versions: 1.5.0
>            Reporter: Darren Davison
>            Assignee: Willem Jiang
>
> Given the following camel DSL:
> from("activemq:queue.testJms.in")                                              
>     .to("jbi:service:urn:oms:testHttp?mep=in-out")                           
>     .to("activemq:queue.testJms.out"); 
> and the following xbean.xml for the smx (3.3) SU:
> <http:endpoint                                                                   
        
>     service="oms:testHttp"                                                   
>     endpoint="testHttp"                                                       
>     role="provider"                                                                 
     
>     locationURI="http://localhost:8080/testP1">                                  
        
> </http:endpoint>   
> then Camel operates correctly (or at least as desired) only if DEBUG logging is enabled
in the org.apache.servicemix.http package.  This seems to be because a DOMSource is returned
(which Camel can convert).  If the log level is reduced (say to WARN) then a StreamSource
object is returned instead which Camel appears unable to convert.  This results in stack traces
such as:
> ERROR - DeadLetterChannel              - Failed delivery for exchangeId:            
     
> ID-davisond-laptop/53380-1232099798317/0-0. On delivery attempt: 0                  
     
> caught: org.apache.camel.RuntimeCamelException:                                     
     
> javax.xml.transform.TransformerException: java.io.IOException: Attempted            
     
> read on closed stream.                                                              
     
> org.apache.camel.RuntimeCamelException:                                             
     
> javax.xml.transform.TransformerException: java.io.IOException: Attempted            
     
> read on closed stream.                                                              
     
>         at                                                                          
     
> org.apache.camel.util.ObjectHelper.invokeMethod(ObjectHelper.java:441)              
     
>         at                                                                          
     
> org.apache.camel.impl.converter.InstanceMethodTypeConverter.convertTo(InstanceMethodTypeCo
> +nverter.java:57) 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message