Hi Senthil,
shame on them for writing a language-specific web serivce!
 
Anyway, if they are the authors of the web service and you are the
client, then you must have gotten the wsdl from them. The wsdl must have
a complexType in it that declares the issuedDate as non-nillable.  But I
can't tell why the line "transfer.setIssueDate(Calendar.getInstance());"
failed.
You'll have to debug it and step through slowly at this point to see if
the instance returned from Calendar.getInstance() is null or not. (If it
is not null, then it is getting nulled out later before the stub
attempts to serialize everything).
This is my guess.
-jeff
 
  _____  

From: Senthivel U S [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 15, 2007 9:38 AM
To: [email protected]
Subject: RE: sending calendar object in axis stub



        Hi Jeff,

         

        Thanks for your comments and I do agree with you. The service
was deployed by third party and I want to consume the service. I have
created my stub using wsdl (Eclipse IDE).

         

        TIA,

        -senthil

         

         

        
  _____  


        From: Walker, Jeff [mailto:[EMAIL PROTECTED] 
        Sent: Monday, October 15, 2007 5:08 PM
        To: [email protected]
        Subject: RE: sending calendar object in axis stub

         

        Hi Senthil,

        Don't pass language specific constructs like Calendar, in a web
service call.

         

        You are better taking the less obvious route; just pass the
minimal amount number fo fields in the Calendar object that can be used
by a client to regenerate the equivalent object on their side. That is,
build a new complexType in XML Schema and use Doc/Lit-wrapped web
services.

         

        The main reason is simply, interoperability. Even of you know
all of your clients will be Java going forward, it's bad practice to
pass language specific objects in a web service. If indeed all of your
clients will always be Java, then you would benefit from RMI or EJB
where you would get a significant speed increase. Web Services is for
interoperability across disparate systems.

        Regards,

        -jeff

         

        
  _____  


        From: Senthivel U S [mailto:[EMAIL PROTECTED]

        Sent: Monday, October 15, 2007 8:27 AM
        To: [email protected]
        Subject: sending calendar object in axis stub

                Hi,

                 

                I have a stub, in that I want to pass calendar object,
while passing I am getting the following error.  Is any serializer to be
included to pass calendar object.

                 

                java.io.IOException: Non nillable element 'issuedDate'
is null.

                        at
org.apache.axis.encoding.ser.BeanSerializer.serialize(BeanSerializer.jav
a:215)

                        at
org.apache.axis.encoding.SerializationContext.serializeActual(Serializat
ionContext.java:1502)

                 

                My code is 

                 

                transfer.setIssueDate(Calendar.getInstance());

                stub.insertTransfer(transfer);

                 

                TIA,

                -senthil

                 

Reply via email to