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

Claus Ibsen updated CAMEL-22112:
--------------------------------
    Issue Type: New Feature  (was: Improvement)

> Allow running Jsonata specification from header
> -----------------------------------------------
>
>                 Key: CAMEL-22112
>                 URL: https://issues.apache.org/jira/browse/CAMEL-22112
>             Project: Camel
>          Issue Type: New Feature
>    Affects Versions: 4.11.0
>            Reporter: Raymond
>            Priority: Minor
>             Fix For: 4.x
>
>
> The XSLT Component allows to run an XSLT stylesheet from a header, using the 
> CamelXsltStylesheet. 
> For example:
> ```xml
> <route id="47cecba2-99a6-469b-b3ed-9f9f3dad813b">
>     <from uri="direct:myxslt"/>
>     <setHeader name="CamelXsltStylesheet">
>         <constant><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; 
> version="1.0">
> <xsl:output method="xml" indent="yes"/>
> <xsl:template match="/">
>     <root>
>         <xsl:apply-templates select="persons"/>
>     </root>
> </xsl:template>
> <xsl:template match="persons/person/name">
>     <div style="color:green">
>         <xsl:value-of select="."/>
>     </div>
> </xsl:template>
> </xsl:stylesheet>]]></constant>
>     </setHeader>
>     <to 
> uri="xslt-saxon:dummy.xsl?contentCache=false&amp;allowTemplateFromHeader=true"/>
>     <removeHeader name="CamelXsltStylesheet"/>
> </route>
> ```
> I would like to also run a 
> [JSONata|https://camel.apache.org/components/4.10.x/jsonata-component.html] 
> script also directly from header. For example using the header "CamelJsonata" 
> or "CamelJsonataScript"
> Note: I couldn't select "camel-jsonata" from the Jira components list.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to