[ 
https://issues.apache.org/activemq/browse/SM-902?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Gert Vanthienen updated SM-902:
-------------------------------

    Attachment: SM-902.patch

I think this patch might at least solve the issue, but I admit it is a very 
naive solution.

Main problem: the NormalizedMessage is always copied, even when only 
e.g.message properties are used in the expression (resulting in some overhead 
in that case).  Any suggestions on how to avoid that?

>  File Binding example error with JaxenStringXPathExpression 
> ------------------------------------------------------------
>
>                 Key: SM-902
>                 URL: https://issues.apache.org/activemq/browse/SM-902
>             Project: ServiceMix
>          Issue Type: Bug
>          Components: servicemix-components
>    Affects Versions: 3.1
>         Environment: window xp, java1.5, 
>            Reporter: Sangwoo Han
>            Priority: Minor
>         Attachments: SM-902.patch
>
>
> I have tried example-file binding with servicemix3.1 (latest version) 
> and the file generated in outbox was empty !! size zero ! 
> So I commented out the rename part (filename property with 
> JaxenStringXPathExpression) 
> and it generated file with original file content. It worked !! 
> Guillaume Nodet(gnodet) suspects a problem with the input stream which is not 
> converted before evaluating 
> the expression.
> ======
>  <sm:component> 
>     <bean class="org.apache.servicemix.components.file.FileWriter"> 
>       <property name="directory" value="D:/outbox" /> 
>       <property name="marshaler"> 
>         <bean 
>           class="org.apache.servicemix.components.util.DefaultFileMarshaler"> 
>         <!-- <property name="fileName"> 
>            <bean 
>                
> class="org.apache.servicemix.expression.JaxenStringXPathExpression"> 
>               <constructor-arg 
>                   value="concat('sample_', /sample/@id, '.xml')" /> 
>        </bean> 
>      </property> 
>      --> 
>      </bean> 
>   </property> 
>    </bean> 
>   </sm:component>

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

Reply via email to