Apologies, it's not related to array types, 'collection' was an attribute of the parameter bean. turns out that was the first null field in the bean. This is the only web method in my web service that takes a javabean so I hadn't encountered this problem before.

This bean is used by hibernate to query a database, is there any way I can define it's attributes as nillable? Otherwise I'll have to assign default non-null values to it's attributes, which will complicate my DAO...

much thanks to anyone with a good idea for a solution (or links!!)

Matthew Kerle wrote:
Hi, I'm passing a query object to a web service that executes a search in hibernate.

public class ImageSearch {
   ... //lots of String attributes
   public String [] keywords; //3 of this type
   ...//more String & Integer attributes
   ... //lots of getter/setters.
}

The query object has 3 attributes that are arrays of Strings (multi-valued lookups), and I'm getting the following error as xFire parses the request and maps it back to a bean. I want the arrays to be allowed to be null, how can I set this?

server:
INFO: Fault occurred!
org.codehaus.xfire.fault.XFireFault: collection is nil, but not nillable. <<<<<<<<<<< "collection is nil, but not nillable" at org.codehaus.xfire.aegis.type.basic.BeanType.readObject(BeanType.java:174) at org.codehaus.xfire.aegis.AegisBindingProvider.readParameter(AegisBindingProvider.java:169) at org.codehaus.xfire.service.binding.AbstractBinding.read(AbstractBinding.java:206) at org.codehaus.xfire.service.binding.WrappedBinding.readMessage(WrappedBinding.java:51) at org.codehaus.xfire.soap.handler.SoapBodyHandler.invoke(SoapBodyHandler.java:42) at org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131) at org.codehaus.xfire.transport.DefaultEndpoint.onReceive(DefaultEndpoint.java:64) at org.codehaus.xfire.transport.AbstractChannel.receive(AbstractChannel.java:38) at org.codehaus.xfire.transport.http.XFireServletController.invoke(XFireServletController.java:304) at org.codehaus.xfire.transport.http.XFireServletController.doService(XFireServletController.java:129) at org.codehaus.xfire.transport.http.XFireServlet.doPost(XFireServlet.java:116)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)




---------------------------------------------------------------------
To unsubscribe from this list please visit:

   http://xircles.codehaus.org/manage_email

Reply via email to