This is a bug and will be fixed soon. Axis2 should not generate minOccurs="0" for Java primitives, for primitives is should be always minOccurs="1" please refer [1].
[1] - https://issues.apache.org/jira/browse/AXIS2-5293 Thanks ! On Wed, Apr 18, 2012 at 9:19 PM, Trenton D. Adams <tre...@athabascau.ca>wrote: > Oh, I should have given you my bash script to make this easy. > > Run it like this... > exam-service/update-exam/**update-status.sh --studentid 1 --invigilatorid > 1 --inventoryid 1 --requeststatus ASSIGNED --requeststatusdate > 2012-01-01T01:01:01 --useridwhoupdated me > > Le 12-04-18 09:43 AM, Trenton D. Adams a écrit : > >> I extracted it from my main maven project, and removed the "code" in it, >> and it still exhibits the same behaviour. "mvn install" will generate >> the aar file, and it appears identical to the way it appears when it's >> included in another maven project as a sub-module. So, it appears to be >> functional for you. >> >> Hopefully this comes through. :D >> >> Thanks. >> >> Le 12-04-18 06:43 AM, Sagara Gunathunga a écrit : >> >>> Can you provide your sample service to reproduce this issue ? >>> >>> Thanks ! >>> >>> On Tue, Apr 17, 2012 at 11:58 PM, Trenton D. >>> Adams<tre...@athabascau.ca>**wrote: >>> >>> I'm using a POJO web service (axis2 1.6.1), I have an argument to my >>>> service defined in the WSDL returned as... >>>> >>>> <xs:element minOccurs="0" name="examRequestID" type="xs:long"/> >>>> >>>> And I get an exception if I don't pass it as an argument. Is this a bug? >>>> It seems similar to >>>> https://issues.apache.org/****jira/browse/AXIS2-4541<https://issues.apache.org/**jira/browse/AXIS2-4541> >>>> <https:/**/issues.apache.org/jira/**browse/AXIS2-4541<https://issues.apache.org/jira/browse/AXIS2-4541> >>>> >, >>>> >>>> but that bug says the fix is 1.6.0, but it doesn't appear to be fixed in >>>> 1.6.1 >>>> >>>> java.lang.****IllegalArgumentException >>>> at sun.reflect.****NativeMethodAccessorImpl.****invoke0(Native Method) >>>> at sun.reflect.****NativeMethodAccessorImpl.****invoke(** >>>> NativeMethodAccessorImpl.java:****39) >>>> at sun.reflect.****DelegatingMethodAccessorImpl.****invoke(** >>>> DelegatingMethodAccessorImpl.****java:25) >>>> at java.lang.reflect.Method.****invoke(Method.java:597) >>>> at org.apache.axis2.rpc.****receivers.RPCUtil.** >>>> invokeServiceClass(RPCUtil.****java:212) >>>> at org.apache.axis2.rpc.****receivers.RPCMessageReceiver.**** >>>> invokeBusinessLogic(****RPCMessageReceiver.java:117) >>>> at org.apache.axis2.receivers.****AbstractInOutMessageReceiver.**** >>>> invokeBusinessLogic(****AbstractInOutMessageReceiver.****java:40) >>>> at org.apache.axis2.receivers.****AbstractMessageReceiver.****receive(* >>>> *AbstractMessageReceiver.java:****110) >>>> at org.apache.axis2.engine.****AxisEngine.receive(AxisEngine.**** >>>> java:181) >>>> at org.apache.axis2.transport.****http.HTTPTransportUtils.** >>>> processHTTPPostRequest(****HTTPTransportUtils.java:172) >>>> at org.apache.axis2.transport.****http.AxisServlet.doPost(** >>>> AxisServlet.java:146) >>>> at javax.servlet.http.****HttpServlet.service(****HttpServlet.java:637) >>>> at javax.servlet.http.****HttpServlet.service(****HttpServlet.java:717) >>>> at org.apache.catalina.core.****ApplicationFilterChain.** >>>> internalDoFilter(****ApplicationFilterChain.java:****290) >>>> at org.apache.catalina.core.****ApplicationFilterChain.****doFilter(** >>>> ApplicationFilterChain.java:****206) >>>> at org.apache.catalina.core.****StandardWrapperValve.invoke(** >>>> StandardWrapperValve.java:233) >>>> at org.apache.catalina.core.****StandardContextValve.invoke(** >>>> StandardContextValve.java:191) >>>> at org.apache.catalina.****authenticator.****AuthenticatorBase.invoke(* >>>> *AuthenticatorBase.java:563) >>>> at org.apache.catalina.core.****StandardHostValve.invoke(** >>>> StandardHostValve.java:127) >>>> at org.apache.catalina.valves.****ErrorReportValve.invoke(** >>>> ErrorReportValve.java:102) >>>> at org.apache.catalina.core.****StandardEngineValve.invoke(** >>>> StandardEngineValve.java:109) >>>> at org.apache.catalina.connector.****CoyoteAdapter.service(** >>>> CoyoteAdapter.java:298) >>>> at org.apache.coyote.http11.****Http11Processor.process(** >>>> Http11Processor.java:859) >>>> at org.apache.coyote.http11.****Http11Protocol$** >>>> Http11ConnectionHandler.****process(Http11Protocol.java:****588) >>>> at org.apache.tomcat.util.net.****JIoEndpoint$Worker.run(** >>>> JIoEndpoint.java:489) >>>> at java.lang.Thread.run(Thread.****java:662) >>>> >>>> >>>> -- >>>> Trenton D. Adams >>>> Senior Systems Analyst/Web Software Developer >>>> Navy Penguins at your service! >>>> Athabasca University >>>> (780) 675-6195 >>>> :wq! >>>> >>>> -- >>>> This communication is intended for the use of the recipient to whom it >>>> is addressed, and may contain confidential, personal, and or privileged >>>> information. Please contact us immediately if you are not the intended >>>> recipient of this communication, and do not copy, distribute, or take >>>> action relying on it. Any communications received in error, or >>>> subsequent reply, should be deleted or destroyed. >>>> --- >>>> >>>> ------------------------------****----------------------------** >>>> --**--------- >>>> >>>> To unsubscribe, e-mail: >>>> java-user-unsubscribe@axis.**a**pache.org <http://apache.org>< >>>> java-user-**unsubscr...@axis.apache.org<java-user-unsubscr...@axis.apache.org> >>>> > >>>> >>>> For additional commands, e-mail: java-user-h...@axis.apache.org >>>> >>>> >>>> >>> >>> >> >> >> >> >> ------------------------------**------------------------------**--------- >> To unsubscribe, e-mail: >> java-user-unsubscribe@axis.**apache.org<java-user-unsubscr...@axis.apache.org> >> >> For additional commands, e-mail: java-user-h...@axis.apache.org >> > > > -- > Trenton D. Adams > Senior Systems Analyst/Web Software Developer > Navy Penguins at your service! > Athabasca University > (780) 675-6195 > :wq! > -- Sagara Gunathunga Blog - http://ssagara.blogspot.com Web - http://people.apache.org/~sagara/ LinkedIn - http://www.linkedin.com/in/ssagara