OFBiz
  1. OFBiz
  2. OFBIZ-3385

Axis2 integration returns "Unsupported Content-Type: text/html;charset=utf-8 Supported ones are: [text/xml]"

    Details

    • Type: Bug Bug
    • Status: Reopened
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: SVN trunk
    • Fix Version/s: None
    • Component/s: framework
    • Labels:
      None

      Description

      I have setup the findPartiesById service to export="true" and tried to call the web service using Netbeans 6.5.

      I received the following error message:

      com.sun.xml.internal.ws.server.UnsupportedMediaException: Unsupported Content-Type: text/html;charset=utf-8 Supported ones are: [text/xml]
              at com.sun.xml.internal.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:284)
              at com.sun.xml.internal.ws.encoding.StreamSOAPCodec.decode(StreamSOAPCodec.java:118)
              at com.sun.xml.internal.ws.encoding.SOAPBindingCodec.decode(SOAPBindingCodec.java:278)
              at com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:180)
              at com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:83)
              at com.sun.xml.internal.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:105)
              at com.sun.xml.internal.ws.api.pipe.Fiber.__doRun(Fiber.java:587)
              at com.sun.xml.internal.ws.api.pipe.Fiber._doRun(Fiber.java:546)
              at com.sun.xml.internal.ws.api.pipe.Fiber.doRun(Fiber.java:531)
              at com.sun.xml.internal.ws.api.pipe.Fiber.runSync(Fiber.java:428)
              at com.sun.xml.internal.ws.client.Stub.process(Stub.java:211)
              at com.sun.xml.internal.ws.client.sei.SEIStub.doProcess(SEIStub.java:124)
              at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:98)
              at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:78)
              at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(SEIStub.java:107)
              at $Proxy28.findPartiesById(Unknown Source)
              at javaapplication7.Main.main(Main.java:74)
      

      Watching the tcp steam with wireshark, I can see that the prefix ns2 is added to the map-Entry items:

      <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
         <S:Body>
            <ns2:findPartiesById xmlns:ns2="http://ofbiz.apache.org/service/">
               <map-Map>
                  <ns2:map-Entry>
                     <ns2:map-Key>
                        <ns2:std-String value="idToFind"/>
                     </ns2:map-Key>
                     <ns2:map-Value>
                        <ns2:std-String value="admin"/>
                     </ns2:map-Value>
                  </ns2:map-Entry>
                  <ns2:map-Entry>
                     <ns2:map-Key>
                        <ns2:std-String value="login.username"/>
                     </ns2:map-Key>
                     <ns2:map-Value>
                        <ns2:std-String value="admin"/>
                     </ns2:map-Value>
                  </ns2:map-Entry>
                  <ns2:map-Entry>
                     <ns2:map-Key>
                        <ns2:std-String value="login.password"/>
                     </ns2:map-Key>
                     <ns2:map-Value>
                        <ns2:std-String value="ofbiz"/>
                     </ns2:map-Value>
                  </ns2:map-Entry>
               </map-Map>
            </ns2:findPartiesById>
         </S:Body>
      </S:Envelope>
      

      If I copy this soap message and paste into SoapUI, the soap call fails. However, if I strip off the ns2 prefix from the map-Entry items (as below), the call succeeds:

      <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
         <S:Body>
            <ns2:findPartiesById xmlns:ns2="http://ofbiz.apache.org/service/">
               <map-Map>
                  <map-Entry>
                     <map-Key>
                        <std-String value="idToFind"/>
                     </map-Key>
                     <map-Value>
                        <std-String value="admin"/>
                     </map-Value>
                  </map-Entry>
                  <map-Entry>
                     <map-Key>
                        <std-String value="login.username"/>
                     </map-Key>
                     <map-Value>
                        <std-String value="admin"/>
                     </map-Value>
                  </map-Entry>
                  <map-Entry>
                     <map-Key>
                        <std-String value="login.password"/>
                     </map-Key>
                     <map-Value>
                        <std-String value="ofbiz"/>
                     </map-Value>
                  </map-Entry>
               </map-Map>
            </ns2:findPartiesById>
         </S:Body>
      </S:Envelope>
      

      My java class is:

      package javaapplication7;
      
      import org.apache.ofbiz.service.MapEntry;
      import org.apache.ofbiz.service.MapKey;
      import org.apache.ofbiz.service.MapMap;
      import org.apache.ofbiz.service.MapValue;
      import org.apache.ofbiz.service.StdString;
      
      public class Main {
      
          public static void main(String[] args) {
      
              try { 
                  org.apache.ofbiz.service.FindPartiesById service = new org.apache.ofbiz.service.FindPartiesById();
                  org.apache.ofbiz.service.FindPartiesByIdPortType port = service.getFindPartiesByIdPort();
      
                  StdString keyString = new StdString();
                  keyString.setValue("idToFind");
      
                  MapKey mapKey = new MapKey();
                  mapKey.setStdString(keyString);
                  
                  StdString valueString = new StdString();
                  valueString.setValue("admin");            
                  
                  MapValue mapValue = new MapValue();
                  mapValue.setStdString(valueString);
      
                  MapEntry mapEntry = new MapEntry();
                  mapEntry.setMapKey(mapKey);
                  mapEntry.setMapValue(mapValue);
      
                  StdString keyStringLogin = new StdString();
                  keyStringLogin.setValue("login.username");
      
                  MapKey mapKeyLogin = new MapKey();
                  mapKeyLogin.setStdString(keyStringLogin);
      
                  StdString valueStringLogin = new StdString();
                  valueStringLogin.setValue("admin");
      
                  MapValue mapValueLogin = new MapValue();
                  mapValueLogin.setStdString(valueStringLogin);
      
                  MapEntry mapEntryLogin = new MapEntry();
                  mapEntryLogin.setMapKey(mapKeyLogin);
                  mapEntryLogin.setMapValue(mapValueLogin);
      
                  StdString keyStringPassword = new StdString();
                  keyStringPassword.setValue("login.password");
      
                  MapKey mapKeyPassword = new MapKey();
                  mapKeyPassword.setStdString(keyStringPassword);
      
                  StdString valueStringPassword = new StdString();
                  valueStringPassword.setValue("ofbiz");
      
                  MapValue mapValuePassword = new MapValue();
                  mapValuePassword.setStdString(valueStringPassword);
      
                  MapEntry mapEntryPassword = new MapEntry();
                  mapEntryPassword.setMapKey(mapKeyPassword);
                  mapEntryPassword.setMapValue(mapValuePassword);
      
                  MapMap myMap = new MapMap();
                  myMap.getMapEntry().add(mapEntry);
                  myMap.getMapEntry().add(mapEntryLogin);
                  myMap.getMapEntry().add(mapEntryPassword);
      
                  javax.xml.ws.Holder<org.apache.ofbiz.service.MapMap> mapMap = 
                          new javax.xml.ws.Holder<org.apache.ofbiz.service.MapMap>(myMap);
      
                  port.findPartiesById(mapMap);
      
              } catch (Exception ex) {
                  ex.printStackTrace();
              }
          }
      }
      
      1. patch.txt
        2 kB
        chris snow
      2. patch2.txt
        2 kB
        chris snow

        Issue Links

          Activity

          Hide
          Jacques Le Roux added a comment -

          It's a moment I haven not looked at that. Could not OFBIZ-4245 be a generalization, Ie being "WS-I Basic Profile compliant"?
          Maybe it's unrelated though I have not much time to think/look at time ATM

          Show
          Jacques Le Roux added a comment - It's a moment I haven not looked at that. Could not OFBIZ-4245 be a generalization, Ie being "WS-I Basic Profile compliant"? Maybe it's unrelated though I have not much time to think/look at time ATM
          Hide
          Adrian Crum added a comment -

          It looks like the project I'm working on will be using REST instead of SOAP. But I would like to help try to solve the SOAP problem(s) in the process.

          I think using the xstream bindings is a good start. We could create converters for the entity engine classes. What do you think?

          Show
          Adrian Crum added a comment - It looks like the project I'm working on will be using REST instead of SOAP. But I would like to help try to solve the SOAP problem(s) in the process. I think using the xstream bindings is a good start. We could create converters for the entity engine classes. What do you think?
          Hide
          chris snow added a comment -

          Thanks Adrian!

          Show
          chris snow added a comment - Thanks Adrian!
          Hide
          Adrian Crum added a comment -

          FYI, I added the XStream library to the project with the hope that the SOAP gurus in the community would use it to solve the problems with OFBiz's SOAP handling.

          I will be working on an OFBiz/ESB integration project soon, so I can help out with solving some of the SOAP problems.

          Show
          Adrian Crum added a comment - FYI, I added the XStream library to the project with the hope that the SOAP gurus in the community would use it to solve the problems with OFBiz's SOAP handling. I will be working on an OFBiz/ESB integration project soon, so I can help out with solving some of the SOAP problems.
          Hide
          chris snow added a comment -

          Hi Mansour,

          What do you think of the xstream bindings: http://xstream.codehaus.org/converters.html? The xstream MapConverter xml is much simpler than the map xml currently generated by ofbiz.

          Cheers,

          Chris

          Show
          chris snow added a comment - Hi Mansour, What do you think of the xstream bindings: http://xstream.codehaus.org/converters.html? The xstream MapConverter xml is much simpler than the map xml currently generated by ofbiz. Cheers, Chris
          Hide
          Mansour Al Akeel added a comment -

          Hello Chris,
          sorry for the late reply. I was using axis2 with jaxbri binding. AFAIR the issue was the xml binding itself. Ofbiz web services uses map based results. And we need to tweak them. For example, you will see an element in the response like "eeval-". You need to edit the wsdl, and append the entity type. For example eeval-Party or eeval-Product. Then you need to modify the binding in the generated stub to match this. Here's what I did, I downloaded the wsdl I need to generate stubs for, modified it, then generated the stubs. After that I modified the xml binding, and the object type. I think it was done in the resulting MapValue class.
          And by the way, if you are using axis2, you may need to add ofbiz namespace to the generated response class. For example FindByIdResponse.java needs the namespace added.
          I am not sure about .NET, so I can't help here. Sorry.

          Show
          Mansour Al Akeel added a comment - Hello Chris, sorry for the late reply. I was using axis2 with jaxbri binding. AFAIR the issue was the xml binding itself. Ofbiz web services uses map based results. And we need to tweak them. For example, you will see an element in the response like "eeval-". You need to edit the wsdl, and append the entity type. For example eeval-Party or eeval-Product. Then you need to modify the binding in the generated stub to match this. Here's what I did, I downloaded the wsdl I need to generate stubs for, modified it, then generated the stubs. After that I modified the xml binding, and the object type. I think it was done in the resulting MapValue class. And by the way, if you are using axis2, you may need to add ofbiz namespace to the generated response class. For example FindByIdResponse.java needs the namespace added. I am not sure about .NET, so I can't help here. Sorry.
          Hide
          chris snow added a comment -

          Hi Mansour,

          Were you having a problem with a .NET client, so some other problem?

          Thanks

          Show
          chris snow added a comment - Hi Mansour, Were you having a problem with a .NET client, so some other problem? Thanks
          Hide
          Mansour Al Akeel added a comment -

          any updates for this ?

          Show
          Mansour Al Akeel added a comment - any updates for this ?
          Hide
          Jacques Le Roux added a comment -

          Hi Chris,

          I will certainly have to work on this, any update?

          Thanks

          Show
          Jacques Le Roux added a comment - Hi Chris, I will certainly have to work on this, any update? Thanks
          Hide
          Jacques Le Roux added a comment -

          Reopened at Chris's demand

          Show
          Jacques Le Roux added a comment - Reopened at Chris's demand
          Hide
          Hans Bakker added a comment -

          Chris thank you for the patch2.txt file: Committed revision 896347.

          Show
          Hans Bakker added a comment - Chris thank you for the patch2.txt file: Committed revision 896347.
          Hide
          chris snow added a comment -

          The original patch that I had uploaded for OFBIZ-3385 only solved some of the problems I was experiencing.

          patch2 fixes the other issues. With patch2, the netbeans generated code (jax-ws) now works. Unfortunately, the .NET code still doesn't work.

          Show
          chris snow added a comment - The original patch that I had uploaded for OFBIZ-3385 only solved some of the problems I was experiencing. patch2 fixes the other issues. With patch2, the netbeans generated code (jax-ws) now works. Unfortunately, the .NET code still doesn't work.
          Hide
          Hans Bakker added a comment -

          Thank you Chris, for the patch: Committed revision 895944.

          Show
          Hans Bakker added a comment - Thank you Chris, for the patch: Committed revision 895944.
          Hide
          chris snow added a comment -

          My colleague has also tried to connect usinf flex 3 (actionscript 3). He has experienced a similar problem that actionscript isn't able to de-serialize the response from the server.

          Show
          chris snow added a comment - My colleague has also tried to connect usinf flex 3 (actionscript 3). He has experienced a similar problem that actionscript isn't able to de-serialize the response from the server.
          Hide
          chris snow added a comment -

          I'm also having problems trying to call findPartiesById using a C# 3.5 client.

          I am getting a valid SOAP response from the server from the client call (shown below the code), but the generated client code doesn't appear to be able to re-use the IN object for storing the OUT value. This is the same problem I had experience with the java code.

          Has anyone managed to generate a SOAP client against the ofbiz generated wsdl and successfully make a call?

          Can you spot where I am going wrong?

          Many thanks in advance,

          Chris

          ------------ C# code ---------------

          using System;
          using System.Collections.Generic;
          using System.Linq;
          using System.Text;
          using System.ServiceModel;
          using ConsoleApplication1.ServiceReference1;
          
          namespace ConsoleApplication1
          {
             class Program
             {
                 static void Main(string[] args)
                 {                      findPartiesByIdPortTypeClient client =
                         new findPartiesByIdPortTypeClient();
          
                     mapEntry[] mapEntryArray = new mapEntry[3];
                     mapEntryArray[0] = makeMap("idToFind", "admin");
                     mapEntryArray[1] = makeMap("login.username", "admin");
                     mapEntryArray[2] = makeMap("login.password", "ofbiz");
          
                     client.findPartiesById(ref mapEntryArray);
          
                     Console.WriteLine(mapEntryArray.Length); // is 0, but should be 3
          
                     Console.Read();
                 }
          
                 static mapEntry makeMap(String keyString, String valString) {
                                stdString mapKeyString = new stdString();
                     stdString mapValString = new stdString();
          
                     mapKeyString.value = keyString;
                     mapValString.value = valString;
          
                     mapKey key = new mapKey();
                     key.stdString = mapKeyString;
          
                     mapValue val = new mapValue();
                     val.Item = mapValString;
                     val.ItemElementName = ItemChoiceType.stdString;
                                mapEntry entry = new mapEntry();
                     entry.mapKey = key;
                     entry.mapValue = val;
          
                     return entry;
                 }
             }
          }
          

          -------------- SOAP Response ----------------

          Date: Wed, 30 Dec 2009 12:00:38 GMT
          Set-Cookie: JSESSIONID=018C937189AF33CDD44D2C69862E5CE1.jvm1; Path=/webtools
          Set-Cookie: OFBiz.Visitor=11818; Expires=Thu, 30-Dec-2010 12:00:38 GMT; Path=/
          Content-Type: text/xml;charset=utf-8
          Vary: Accept-Encoding
          Keep-Alive: timeout=15, max=100
          Connection: Keep-Alive
          Transfer-Encoding: chunked
          
          4e4
          <?xml version="1.0" encoding="utf-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><axis2ns7:findPartiesByIdResponse xmlns:axis2ns7="http://ofbiz.apache.org/service/"><map-Map>
                 <map-Entry>
                     <map-Key>
                         <std-String value="responseMessage"></std-String>
                     </map-Key>
                     <map-Value>
                         <std-String value="success"></std-String>
                     </map-Value>
                 </map-Entry>
                 <map-Entry>
                     <map-Key>
                         <std-String value="party"></std-String>
                     </map-Key>
                     <map-Value>
                         <eeval-Party createdStamp="2009-12-24 16:13:30.949" createdTxStamp="2009-12-24 16:13:30.946" lastUpdatedStamp="2009-12-24 16:13:31.892" lastUpdatedTxStamp="2009-12-24 16:13:31.553" partyId="admin" partyTypeId="PERSON"></eeval-Party>
                     </map-Value>
                 </map-Entry>
                 <map-Entry>
                     <map-Key>
                         <std-String value="partiesFound"></std-String>
                     </map-Key>
                     <map-Value>
                         <col-Collection></col-Collection>
                     </map-Value>
                 </map-Entry>
             </map-Map></axis2ns7:findPartiesByIdResponse></soapenv:Body></soapenv:Envelope>
          0
          
          Show
          chris snow added a comment - I'm also having problems trying to call findPartiesById using a C# 3.5 client. I am getting a valid SOAP response from the server from the client call (shown below the code), but the generated client code doesn't appear to be able to re-use the IN object for storing the OUT value. This is the same problem I had experience with the java code. Has anyone managed to generate a SOAP client against the ofbiz generated wsdl and successfully make a call? Can you spot where I am going wrong? Many thanks in advance, Chris ------------ C# code --------------- using System ; using System .Collections.Generic; using System .Linq; using System .Text; using System .ServiceModel; using ConsoleApplication1.ServiceReference1; namespace ConsoleApplication1 { class Program { static void Main(string[] args) { findPartiesByIdPortTypeClient client = new findPartiesByIdPortTypeClient(); mapEntry[] mapEntryArray = new mapEntry[3]; mapEntryArray[0] = makeMap( "idToFind" , "admin" ); mapEntryArray[1] = makeMap( "login.username" , "admin" ); mapEntryArray[2] = makeMap( "login.password" , "ofbiz" ); client.findPartiesById(ref mapEntryArray); Console.WriteLine(mapEntryArray.Length); // is 0, but should be 3 Console.Read(); } static mapEntry makeMap( String keyString, String valString) { stdString mapKeyString = new stdString(); stdString mapValString = new stdString(); mapKeyString.value = keyString; mapValString.value = valString; mapKey key = new mapKey(); key.stdString = mapKeyString; mapValue val = new mapValue(); val.Item = mapValString; val.ItemElementName = ItemChoiceType.stdString; mapEntry entry = new mapEntry(); entry.mapKey = key; entry.mapValue = val; return entry; } } } -------------- SOAP Response ---------------- Date: Wed, 30 Dec 2009 12:00:38 GMT Set-Cookie: JSESSIONID=018C937189AF33CDD44D2C69862E5CE1.jvm1; Path=/webtools Set-Cookie: OFBiz.Visitor=11818; Expires=Thu, 30-Dec-2010 12:00:38 GMT; Path=/ Content-Type: text/xml;charset=utf-8 Vary: Accept-Encoding Keep-Alive: timeout=15, max=100 Connection: Keep-Alive Transfer-Encoding: chunked 4e4 <?xml version= "1.0" encoding= "utf-8" ?><soapenv:Envelope xmlns:soapenv= "http: //schemas.xmlsoap.org/soap/envelope/" ><soapenv:Body><axis2ns7:findPartiesByIdResponse xmlns:axis2ns7= "http://ofbiz.apache.org/service/" ><map-Map> <map-Entry> <map-Key> <std- String value= "responseMessage" ></std- String > </map-Key> <map-Value> <std- String value= "success" ></std- String > </map-Value> </map-Entry> <map-Entry> <map-Key> <std- String value= "party" ></std- String > </map-Key> <map-Value> <eeval-Party createdStamp= "2009-12-24 16:13:30.949" createdTxStamp= "2009-12-24 16:13:30.946" lastUpdatedStamp= "2009-12-24 16:13:31.892" lastUpdatedTxStamp= "2009-12-24 16:13:31.553" partyId= "admin" partyTypeId= "PERSON" ></eeval-Party> </map-Value> </map-Entry> <map-Entry> <map-Key> <std- String value= "partiesFound" ></std- String > </map-Key> <map-Value> <col-Collection></col-Collection> </map-Value> </map-Entry> </map-Map></axis2ns7:findPartiesByIdResponse></soapenv:Body></soapenv:Envelope> 0
          Hide
          chris snow added a comment - - edited

          I modified the SOAPEventHandler sendError method to set the content type to text/xml:

          public class SOAPEventHandler implements EventHandler {
          ...
             private void sendError(HttpServletResponse res, String errorMessage) throws EventHandlerException {
                  try {            
                      // setup the response
                      res.setContentType("text/xml");
          ...
          

          This has resolved the content type error message, but I now get the following error message:

          javax.xml.ws.WebServiceException: Unexpected response element Response expected: {http://ofbiz.apache.org/service/}findPartiesByIdResponse
                  at com.sun.xml.internal.ws.client.sei.ResponseBuilder$RpcLit.readResponse(ResponseBuilder.java:603)
                  at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:110)
                  at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:78)
                  at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(SEIStub.java:107)
                  at $Proxy28.findPartiesById(Unknown Source)
                  at javaapplication7.Main.main(Main.java:74)
          

          It seems that the service is expecting the login.username and login.password parameters, but because of the namespace issue isn't detecting them from the request. Instead of returning the error in a <findPartiesByIdResponse> element, the service is returning the error in a generic <Response> element. It also looks like two response's are being returned?

          HTTP/1.1 200 OK
          
          Date: Mon, 28 Dec 2009 20:15:22 GMT
          
          Set-Cookie: JSESSIONID=484E688A4DC10B5504C9035B4AA3C1EF.jvm1; Path=/webtools
          
          Set-Cookie: OFBiz.Visitor=10305; Expires=Tue, 28-Dec-2010 20:15:22 GMT; Path=/
          
          Content-Type: text/xml;charset=utf-8
          
          Vary: Accept-Encoding
          
          Keep-Alive: timeout=15, max=99
          
          Connection: Keep-Alive
          
          Transfer-Encoding: chunked
          
          
          
          1e6
          
          <?xml version="1.0" encoding="utf-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><Response><map-Map>
                  <map-Entry>
                      <map-Key>
                          <std-String value="errorMessage"></std-String>
                      </map-Key>
                      <map-Value>
                          <std-String value="Problem processing the service"></std-String>
                      </map-Value>
                  </map-Entry>
              </map-Map></Response></soapenv:Body></soapenv:Envelope>
          
          24b
          
          <?xml version="1.0" encoding="utf-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><Response><map-Map>
                  <map-Entry>
                      <map-Key>
                          <std-String value="errorMessage"></std-String>
                      </map-Key>
                      <map-Value>
                          <std-String value="User authorization is required for this service: findPartiesById (User authorization is required for this service: findPartiesById)"></std-String>
                      </map-Value>
                  </map-Entry>
              </map-Map></Response></soapenv:Body></soapenv:Envelope>
          
          0
          
          
          Show
          chris snow added a comment - - edited I modified the SOAPEventHandler sendError method to set the content type to text/xml: public class SOAPEventHandler implements EventHandler { ... private void sendError(HttpServletResponse res, String errorMessage) throws EventHandlerException { try { // setup the response res.setContentType( "text/xml" ); ... This has resolved the content type error message, but I now get the following error message: javax.xml.ws.WebServiceException: Unexpected response element Response expected: {http: //ofbiz.apache.org/service/}findPartiesByIdResponse at com.sun.xml.internal.ws.client.sei.ResponseBuilder$RpcLit.readResponse(ResponseBuilder.java:603) at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:110) at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:78) at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(SEIStub.java:107) at $Proxy28.findPartiesById(Unknown Source) at javaapplication7.Main.main(Main.java:74) It seems that the service is expecting the login.username and login.password parameters, but because of the namespace issue isn't detecting them from the request. Instead of returning the error in a <findPartiesByIdResponse> element, the service is returning the error in a generic <Response> element. It also looks like two response's are being returned? HTTP/1.1 200 OK Date: Mon, 28 Dec 2009 20:15:22 GMT Set-Cookie: JSESSIONID=484E688A4DC10B5504C9035B4AA3C1EF.jvm1; Path=/webtools Set-Cookie: OFBiz.Visitor=10305; Expires=Tue, 28-Dec-2010 20:15:22 GMT; Path=/ Content-Type: text/xml;charset=utf-8 Vary: Accept-Encoding Keep-Alive: timeout=15, max=99 Connection: Keep-Alive Transfer-Encoding: chunked 1e6 <?xml version= "1.0" encoding= "utf-8" ?><soapenv:Envelope xmlns:soapenv= "http: //schemas.xmlsoap.org/soap/envelope/" ><soapenv:Body><Response><map-Map> <map-Entry> <map-Key> <std- String value= "errorMessage" ></std- String > </map-Key> <map-Value> <std- String value= "Problem processing the service" ></std- String > </map-Value> </map-Entry> </map-Map></Response></soapenv:Body></soapenv:Envelope> 24b <?xml version= "1.0" encoding= "utf-8" ?><soapenv:Envelope xmlns:soapenv= "http: //schemas.xmlsoap.org/soap/envelope/" ><soapenv:Body><Response><map-Map> <map-Entry> <map-Key> <std- String value= "errorMessage" ></std- String > </map-Key> <map-Value> <std- String value= "User authorization is required for this service: findPartiesById (User authorization is required for this service: findPartiesById)" ></std- String > </map-Value> </map-Entry> </map-Map></Response></soapenv:Body></soapenv:Envelope> 0

            People

            • Assignee:
              Unassigned
              Reporter:
              chris snow
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Development