function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Chester CheeChester Chee 

java.lang.IllegalArgumentException: the object parameter to marshal() is not marshallable

Hi,

 

I used Enterprise WSDL with -XautoNameResolution for wsimport. Classes are generated fine. Everything was compiled fine. But when I invoke binding.login(username, password) where binding is Soap class generated by wsimport. It gives me an error:-

 

 

Exception in thread "main" javax.xml.ws.WebServiceException: java.lang.IllegalArgumentException: the object parameter to marshal() is not marshallable
        at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:194)
        at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:93)
        at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:105)
        at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:629)
        at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:588)
        at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:573)
        at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:470)
        at com.sun.xml.ws.client.Stub.process(Stub.java:319)
        at com.sun.xml.ws.client.sei.SEIStub.doProcess(SEIStub.java:157)
        at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:109)
        at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:89)
        at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:140)
        at $Proxy36.login(Unknown Source)
        at SforceEnterpriseConnector.login(SforceEnterpriseConnector.java:110)
        at SforceEnterpriseConnector.main(SforceEnterpriseConnector.java:155)
Caused by: java.lang.IllegalArgumentException: the object parameter to marshal() is not marshallable
        at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:288)
        at com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:168)
        at com.sun.xml.ws.message.jaxb.MarshallerBridge.marshal(MarshallerBridge.java:80)
        at com.sun.xml.bind.api.Bridge.marshal(Bridge.java:141)
        at com.sun.xml.bind.api.Bridge.marshal(Bridge.java:133)
        at com.sun.xml.ws.message.jaxb.JAXBHeader.writeTo(JAXBHeader.java:186)
        at com.sun.xml.ws.message.AbstractMessageImpl.writeTo(AbstractMessageImpl.java:135)
        at com.sun.xml.ws.encoding.StreamSOAPCodec.encode(StreamSOAPCodec.java:109)
        at com.sun.xml.ws.encoding.SOAPBindingCodec.encode(SOAPBindingCodec.java:278)
        at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:155)
        ... 14 more
Java Result: 1

 Anyone has any idea on what I did wrong? I am very sure the credential for login is good because it works if I use Partner WSDL. Any help is greatly appreciated. Thanks in advance.

 

 

Chester CheeChester Chee

I forgot to mention, I am using Netbeans 6.8 with JAX-WS plugin. Can any guru here shed some lights here please? Thanks in advance.