public static Mediator defineSequence(SynapseConfiguration config, OMElement ele,
Properties properties) {
String name = ele.getAttributeValue(new QName(XMLConfigConstants.NULL_NAMESPACE, "name"));
if (name != null) {
Mediator mediator = MediatorFactoryFinder.getInstance().getMediator(ele, properties);
config.addSequence(name, mediator);
// mandatory sequence is treated as a speciall sequence because it will be fetched for
// each and every message and keeps a direct reference to that from the configuration
// this also limits the ability of the mandatory sequence to be dynamic
if (SynapseConstants.MANDATORY_SEQUENCE_KEY.equals(name)) {