Hi Sivaramya,

We decided to go for a class mediator without using existing validate
mediator to avoid building the message. However, on a second thought, if we
add the class mediator inside the insequence of the resource as below,

*   <resource methods="POST" url-mapping="/order" faultSequence="fault">*
*      <inSequence>*
*         <class name ="org.wso2.carbon.apimgt.JsonshemaValidator"/>*
*         <property name="api.ut.backendRequestTime"*
*                   expression="get-property('SYSTEM_TIME')"/>*


AFAIK in synapse level, it will check whether there are any mediators in
the in-sequence that is content-aware. If it is content-aware, in synapse
level relevant message will be build before starting the in-Sequence. In
that case, since we are using the property mediator in insequence, which is
content-aware, regardless of whether our class mediator is content-aware or
not, the relevant message will be built. In that case, main reason for
creating a custom class mediator is invalidated. So how are we going to
handle this?

If we are ok to build the message before JsonSchemaValidation, can't we use
the existing validate mediator itself? WDYT?

Thanks.

Regards,
Megala
_______________________________________________
Architecture mailing list
[email protected]
https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture

Reply via email to