camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From APinto <armeniopi...@gmail.com>
Subject Transform, Camel and null message bodies
Date Thu, 21 Nov 2013 12:22:09 GMT
Hello all!

In this specific application of Camel, we have the requirement of writing as
much as possible message processing code in Python/Jython.

This took me to <transform> and <python>. The solution would look like (we
are using Camel 2.12.1 and Jython 2.5.3):

...
<tranform>
    <python>resource:classpath:transformation.py</python>
</transform>
...

The Jython code would look like, for example:

request.headers['MyHeader']='Something'

The problem is that the routes are failing saying that the body is null
after the transformation. If I add the line response.body=request.body to
the Jython script, the compilation fails saying that the name 'response' is
not defined.

I searched as much as I could but I couldn't find a solution to the problem.
Could any of you help me please?

Thank you very much for your attention, regards,

AP



--
View this message in context: http://camel.465427.n5.nabble.com/Transform-Camel-and-null-message-bodies-tp5743617.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message