Petals SE XSLT

The SE XSLT should be able to add properties to the reply message

Details

  • Type: Improvement Request Improvement Request
  • Status: New New
  • Resolution: Unresolved
  • Affects Version/s: 2.3.2
  • Fix Version/s: None
  • Component/s: None
  • Security Level: Public
  • Description:
    Hide

    Now,the SE XSLT transforms the input message into an output message according to an XSL.

    It should be able to include properties into the output message. These properties are also generated from XSLs.
    Properties to put in the output message could be defined as following in the provide SU using a new parameter 'output-properties':

    <xslt:stylesheet>main.xsl</xslt:stylesheet>
           <xslt:xsl-parameters>
               ...
           </xslt:xsl-parameters>
           <xslt:output-properties>
                <xslt:output-property name="prop1" xsl="prop1.xsl" />
                <xslt:output-property name="prop2" xsl="prop2.xsl" />
                ...
           </xslt:output-properties>

    To generate output property containing text, use a XSL stylesheet generating text:

    <stylesheet version="1.0" xmlns="http://www.w3.org/1999/XSL/Transform">
       <output method="text"/>
    
       <template match="msg">Found it!</template>
    
    </stylesheet>

    XSL generating the output property content is invoked using global variables defined by incoming properties (PETALSSEXSLT-12) and <xsl-parameters>

    Show
    Now,the SE XSLT transforms the input message into an output message according to an XSL. It should be able to include properties into the output message. These properties are also generated from XSLs. Properties to put in the output message could be defined as following in the provide SU using a new parameter 'output-properties':
    <xslt:stylesheet>main.xsl</xslt:stylesheet>
           <xslt:xsl-parameters>
               ...
           </xslt:xsl-parameters>
           <xslt:output-properties>
                <xslt:output-property name="prop1" xsl="prop1.xsl" />
                <xslt:output-property name="prop2" xsl="prop2.xsl" />
                ...
           </xslt:output-properties>
    To generate output property containing text, use a XSL stylesheet generating text:
    <stylesheet version="1.0" xmlns="http://www.w3.org/1999/XSL/Transform">
       <output method="text"/>
    
       <template match="msg">Found it!</template>
    
    </stylesheet>
    XSL generating the output property content is invoked using global variables defined by incoming properties (PETALSSEXSLT-12) and <xsl-parameters>
  • Environment:
    -

Activity

Hide
Vincent Zurczak added a comment - Thu, 16 Sep 2010 - 20:35:26 +0200

I am not sure to understand what you want to do.
I here try to rephrase. Let me know if I am right or not.

  1. The usual XSL transformation is executed.
  2. Then, for each output property:
    1. Load the associated XSL.
    2. Apply it to the initial transformation result.
    3. The result of this second XSL transformation is stored into an output property of the message.

Is there a real use case for this?
I mean, is there somebody that will use that?

Show
Vincent Zurczak added a comment - Thu, 16 Sep 2010 - 20:35:26 +0200 I am not sure to understand what you want to do. I here try to rephrase. Let me know if I am right or not.
  1. The usual XSL transformation is executed.
  2. Then, for each output property:
    1. Load the associated XSL.
    2. Apply it to the initial transformation result.
    3. The result of this second XSL transformation is stored into an output property of the message.
Is there a real use case for this? I mean, is there somebody that will use that?
Hide
Christophe DENEUX added a comment - Fri, 17 Sep 2010 - 08:44:55 +0200

No, it's not what I mean.

1/ The ususal XSL transformation is executed using the XML payload or attachment,
2/ For each 'output-property' defined in the SU, a new XSL transformation is executed to defined its content. Inputs of this transformation are:

  • input properties as global parameter,
  • 'xsl-parameter' as global parameter,
  • input XML payload

Why this feature ? To be able to transmit message properties when the SE XSL is used in a service chain orchestrated by the SE EIP (see the use-case described by SPVEOLIAE-60 replacing interceptors by native features). And more generally, component must be able to process message properties as the XML payload.

Note: About performances, these XSL transformations can be executed concurrently using a thread-pool of the component and java Future.

Show
Christophe DENEUX added a comment - Fri, 17 Sep 2010 - 08:44:55 +0200 No, it's not what I mean. 1/ The ususal XSL transformation is executed using the XML payload or attachment, 2/ For each 'output-property' defined in the SU, a new XSL transformation is executed to defined its content. Inputs of this transformation are:
  • input properties as global parameter,
  • 'xsl-parameter' as global parameter,
  • input XML payload
Why this feature ? To be able to transmit message properties when the SE XSL is used in a service chain orchestrated by the SE EIP (see the use-case described by SPVEOLIAE-60 replacing interceptors by native features). And more generally, component must be able to process message properties as the XML payload. Note: About performances, these XSL transformations can be executed concurrently using a thread-pool of the component and java Future.

People

Dates

  • Created:
    Thu, 16 Sep 2010 - 19:22:00 +0200
    Updated:
    Fri, 17 Sep 2010 - 08:44:55 +0200