[mule-user] Null payload returned

39 views
Skip to first unread message

Ian Godman

unread,
Feb 14, 2007, 5:55:48 PM2/14/07
to us...@mule.codehaus.org
Hi

I am trying to use Mule in an application, I am not sure I am using it in the right way.

The application currently run on a single server using Mule/Spring/Acegy/Hypersonic/Hibernate/Jetty

I have everything working using Mule API send direct method. How ever I ocasionaly get a "The mule manager is running synchronously, a null message payload will be returned" warning. I need things to be synconious.

I have searched the internet and can find no explanation of this nor any mention of it in the documentation.

I tried changing the code to use a furure result but just get a [B exception message. I have tried the 1.4 snapshot release but that is no different.

Changed to axis and had issues with seriliasers, tried XFire and got no where just confused.

I have a completely working system except for the ocasional null payload.

Can anyone point me in the right direction?




Inbox full of unwanted email? Get leading protection and 1GB storage with All New Yahoo! Mail.

Andrew Perepelytsya

unread,
Feb 15, 2007, 9:40:06 PM2/15/07
to us...@mule.codehaus.org
Ian,

That is not a code error, but rather a configuration problem on your side. Post configs and details.

I don't think [B is an error, that's a standard JDK syntax for denoting a byte[] class.

Andrew

Ian Godman

unread,
Feb 16, 2007, 10:30:28 AM2/16/07
to us...@mule.codehaus.org
The [B is not my main concern, I get that error when I tried to recode to use asynconious instead of synconous.

I get the Null payload ocasionaly when using sendDirect. I want it to be synconous. It gives me a warning essentualy saying that my client in running in the mode I require and then says its returing a null payload which is usless. I can find no documentation on this at all.

Most of the time it works perfectly just as I want it to. The problem is this null payload it returns for no disernable reason that I can see.

Code that sends to Mule:

UMOMessage result = messageClient.sendDirect(serviceName, null, message, null);

Mule config:

 <mule-configuration id="Mule_Echo_Sample" version="1.0">
    <description> MyApp </description>

    <container-context className="org.mule.extras.spring.SpringContainerContext">
        <properties>
            <property name="configFile" value="beans.xml"/>
        </properties>
    </container-context>

   <model name="MyModel">
         <mule-descriptor name="service" implementation="serviceBean">
        </mule-descriptor>
    </model>
</mule-configuration>

serviceBean is defined in beans.xml as:

  <bean id="serviceBean" class="com......serviceImpl">
  </bean>

Any idea why Mule is deciding to give me a null payload sometimes and not others?


Copy addresses and emails from any email account to Yahoo! Mail - quick, easy and free. Do it now...

Andrew Perepelytsya

unread,
Feb 16, 2007, 10:38:11 AM2/16/07
to us...@mule.codehaus.org
Ian,

It could be an issue with the way a client is being used. Are you using the same instance or creating a new one for each call? Then, have you tried sending to the inbound component's endpoint, and not use the sendDirect call?

It's hard to tell anything without full configs and logs.

Andrew

On 2/16/07, Ian Godman <ian...@yahoo.co.uk > wrote:
The [B is not my main concern, I get that error when I tried to recode to use asynconious instead of synconous.

I get the Null payload ocasionaly when using sendDirect. I want it to be synconous. It gives me a warning essentualy saying that my client in running in the mode I require and then says its returing a null payload which is usless. I can find no documentation on this at all.

Most of the time it works perfectly just as I want it to. The problem is this null payload it returns for no disernable reason that I can see.

Code that sends to Mule:

UMOMessage result = messageClient.sendDirect (serviceName, null, message, null);

Ian Godman

unread,
Feb 16, 2007, 3:51:28 PM2/16/07
to us...@mule.codehaus.org
Each session uses the same client instance. In my testing so far only have one session.

I have tried defining an end point but that still did not work.

What is still confusing is that it works fine most of the time with sendDirect.

What I am trying to do is package up a set of values in a POJO and send it to a "backend" for processing the results of that processing is returned to the caller.

I think I have worked out why the AXIS version had problems with the serialisation, I have a List in the return type which it needs to know how to serialise.

The application runs on a single server (only JVM required) but by using Mule I am hoping to be able to change the configuration (and maybe at most my 'send' method) and have the software running not only on multiple machines but also from multiple "front ends".

In reality I am not even sure I understand all the bit enough to know that I am not wandering off into a maze with no solution or  an eventual dead end.

Andrew Perepelytsya

unread,
Feb 16, 2007, 4:00:32 PM2/16/07
to us...@mule.codehaus.org
Just to eliminate any threading issues in client, try using a new MuleClient reference for each send.

Ian Godman

unread,
Feb 16, 2007, 4:18:39 PM2/16/07
to us...@mule.codehaus.org
Tried using a new mule client for each call, no difference.


The all-new Yahoo! Mail goes wherever you go - free your email address from your Internet provider.
Reply all
Reply to author
Forward
0 new messages