On 11 Jul 2007, at 11:14, Ruwan Linton wrote:

Hi Nick,

Please see the comments in line in the mediator code;


---

Code Using injectMessage
------------------------

public boolean mediate(MessageContext ctx) {
         final SynapseEnvironment env = ctx.getEnvironment();

         final MessageContext newCtx = env.createMessageContext();



I think the above line is where you are doing something wrong, because it seems that your newCtx does not have a Axis2 ConfigurationContext associated
with it.

Use the following method to get the newCtx instead and try,

final MessageContext newCtx = new Axis2MessageContext (((Axis2MessageContext)
ctx).getAxis2MessageContext(), ctx.getConfiguration(), env);

Just give it a try and let me know if there are any issues.


- that works. Many thanks.

I thought the null pointer was something to do with missing context info. from the exception but couldn't work out which context I was missing :-(

Thanks again for your help

Nick



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

Reply via email to