Hi ESB team

Suppose we have a sample payloadFactory configuration as follows

<payloadFactory media-type="json">
        <format>json body</format>
        <args>
            <arg evaluator="xml" expression="/person/gender"/>
            <arg value="2013"/>
            <arg evaluator="json" expression="$fname"/>
        </args>
</payloadFactory>


1. Is there any use cases such that *media-type="json"* and <*arg
evaluator="xml"*  will be used
2. Possible use case of *media-type="xml"* and <*arg
evaluator="json"*(opposite of the question one)

And some synapse code problems
payloadFactoryMediator has has methods called getJsonPathArgumentList() and
getXPathArgumentList(). I used these methods to access arguments, issue was
the value type argument (<arg value="2013"/>) is returned from both methods.

3. Is this a bug or intended behavior.

And a suggestion
4 .How about giving the config something like follows (omitting the
evaluator because in code level it is handled in that way). Hope this
simplifies coding and understandability.
<args>
            <arg expression="/person/gender"/>
            <arg value="2013"/>
            <arg jsonpath="$fname"/>
</args>



-- 
*Susinda Perera*
Software Engineer
Mobile:(+94)716049075

WSO2 Inc. http://wso2.com/
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to