private Log log = LogFactory.getLog(getClass());
public void receive(MessageContext mc) throws AxisFault {
log.debug("receiving message");
SynapseEnvironment env = Axis2SynapseEnvironmentFinder
.getSynapseEnvironment(mc);
////////////////////////////////////////////////////////////////////////
// SynapseEnvironment is set as a property in MessageContext. This is due
// use we can expect in ServiceMeidatorProcessor and many extensions yet to come
// So it a mediator uses EnvironmentAware, that mediator will be injected with the correct environment
mc.setProperty(
org.apache.synapse.Constants.MEDIATOR_SYNAPSE_ENV_PROPERTY,
env);
////////////////////////////////////////////////////////////////////////
SynapseMessage smc = new Axis2SynapseMessage(mc);
env.injectMessage(smc);
///////////////////////////////////////////////////////////////////////
// Response handling mechanism for 200/202 and 5XX
// smc.isResponse =true then the response will be handle with 200 OK
// else, response will be 202 OK without no http body