//copyint properties as configured in the module.xml properties. Module xml has several
//properties which gives comma seperated lists of property names that have to be copited
//from various places when creating related messages.
AxisModule axisModule = SandeshaUtil.getAxisModule();
Parameter propertiesFromRefMsg = axisModule.getParameter(Sandesha2Constants.propertiesToCopyFromReferenceMessage);
if (propertiesFromRefMsg!=null) {
String value = (String) propertiesFromRefMsg.getValue();
if (value!=null) {
value = value.trim();
String[] propertyNames = value.split(",");
for (int i=0;i<propertyNames.length;i++) {
String propertyName = propertyNames[i];
Object val = referenceMessage.getProperty(propertyName);
if (val!=null) {
newMessageContext.setProperty(propertyName,val);
}
}
}
}
Parameter propertiesFromRefReqMsg = axisModule.getParameter(Sandesha2Constants.propertiesToCopyFromReferenceRequestMessage);
OperationContext referenceOpCtx = referenceMessage.getOperationContext();
MessageContext referenceRequestMessage = null;
if (referenceOpCtx!=null)
referenceRequestMessage=referenceOpCtx.getMessageContext(OperationContextFactory.MESSAGE_LABEL_IN_VALUE);