Hi Ruwan!

While the goal of the "pre-mediate" sequence is a fine one, I think the name is unfortunate - Synapse is about mediation, and what goes *in* the "pre-mediate" sequence? Mediators! :) So it's not really "pre" mediation at all, it's more like a "global" or "master" sequence.

Second, the flow seems a little unclear now with yet another "automatic" rule to the sequencing. An alternate idea: have a "master" sequence which runs for every message, and a "handleProxyOrMessage" mediator in there which is where the proxy/message mediation happens. That way you could also put things *after* the proxy/message mediation (I'd think people would want common post-processing almost as much as common pre-processing).

So the default master sequence would be:

<sequence name="master">
 <handleProxyOrMessage/>
</sequence>

And I'd be able to do:

<sequence name="master">
 <log><property name="msg" value="In mediation"/></log>
 <handleProxyOrMessage/>
 <log><property name="msg" value="Leaving mediation"/></log>
</sequence>

What do you think?

Thanks,
--Glen

P.S.  Re: the registry lookup - isn't the result cached?

Ruwan Linton (JIRA) wrote:
pre-mediate sequence should not be looked up from the registry
--------------------------------------------------------------

                 Key: SYNAPSE-291
                 URL: https://issues.apache.org/jira/browse/SYNAPSE-291
             Project: Synapse
          Issue Type: Bug
    Affects Versions: 1.2-QA-B1
         Environment: all envs
            Reporter: Ruwan Linton
            Priority: Critical
             Fix For: 1.2


The newly added pre-mediate mandatory sequence causes registry lookup for each 
and every request if the pre-mediate sequence is not there in the local 
configuration. This leads to performance drawbacks and hence pre-mediate should 
only be looked up in the local configuration.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to