1 Reply Latest reply on Jul 15, 2007 11:47 PM by Marc de kwant

    webservice response problems

    Marc de kwant
      hi,

      Iam trying to get my query webservice to function, but iam having severe problems. No information can be found to solve my problem, so Iam hoping some here can assist me in solving my problem.

      Iam getting errors (

      RPC Fault faultString="Unexpected parameter 'queryResponse' found in input arguments." faultCode="Client.Input" faultDetail="null"]
      at mx.rpc.soap::Operation/mx.rpc.soap:Operation::createFaultEvent()
      at mx.rpc.soap::Operation/ http://www.adobe.com/2006/flex/mx/internal::invokePendingCall()
      at mx.rpc.soap::Operation/send()
      at Function/ http://adobe.com/AS3/2006/builtin::apply()
      at mx.rpc.soap.mxml::Operation/send()
      at AlfrescoQuery/___Button1_click()
      )

      I have tried everything I can think of, but to no avail... below is my flex code Iam using:

      <?xml version="1.0" encoding="utf-8"?>
      <mx:Application xmlns:mx=" http://www.adobe.com/2006/mxml" layout="absolute">

      <mx:Script>
      <![CDATA[

      import mx.rpc.events.ResultEvent;
      public function queryResultHandler(event:ResultEvent):void {

      }

      ]]>
      </mx:Script>

      <mx:WebService id="alfServ"
      wsdl=" http://myalfresco/alfresco/wsdl/repository-service.wsdl"
      endpointURI="http:/myalfresco8/alfresco/api/RepositoryService">
      <mx:operation name="query" result="queryResultHandler(event)">
      <mx:request>
      <store>
      <ns1:scheme xmlns:ns1=" http://www.alfresco.org/ws/model/content/1.0">workspace</ns1:scheme>
      <ns2:address xmlns:ns2=" http://www.alfresco.org/ws/model/content/1.0">SpacesStore</ns2:address>
      </store>
      <query>
      <ns3:language xmlns:ns3=" http://www.alfresco.org/ws/model/content/1.0">lucene</ns3:language>
      <ns4:statement xmlns:ns4=" http://www.alfresco.org/ws/model/content/1.0">TEXT:'alfresco development team'</ns4:statement>
      </query>
      <includeMetaData>false</includeMetaData>
      </mx:request>
      </mx:operation>
      </mx:WebService>

      <mx:Button x="88" y="45" label="Button" click="alfServ.query.send()"/>

      </mx:Application>


      But this does not work... HELP ME PLEASE....

      below included soap calls for the request and the response that is recieved....

      <?xml version="1.0" encoding="UTF-8"?>
      <soapenv:Envelope xmlns:soapenv=" http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd=" http://www.w3.org/2001/XMLSchema" xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance">
      <soapenv:Body>
      <query xmlns=" http://www.alfresco.org/ws/service/repository/1.0">
      <store>
      <ns1:scheme xmlns:ns1=" http://www.alfresco.org/ws/model/content/1.0">workspace</ns1:scheme>
      <ns2:address xmlns:ns2=" http://www.alfresco.org/ws/model/content/1.0">SpacesStore</ns2:address>
      </store>
      <query>
      <ns3:language xmlns:ns3=" http://www.alfresco.org/ws/model/content/1.0">lucene</ns3:language>
      <ns4:statement xmlns:ns4=" http://www.alfresco.org/ws/model/content/1.0">TEXT:'alfresco development team'</ns4:statement>
      </query>
      <includeMetaData>false</includeMetaData>
      </query>
      </soapenv:Body>
      </soapenv:Envelope>



      RESPONSE


      <soapenv:Envelope
      xmlns:soapenv=" http://schemas.xmlsoap.org/soap/envelope/"
      xmlns:xsd=" http://www.w3.org/2001/XMLSchema"
      xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance">
      <soapenv:Body>
      <queryResponse
      xmlns=" http://www.alfresco.org/ws/service/repository/1.0">
      <queryReturn>
      <querySession>
      52dbfef8-306d-11dc-9782-6160ed7fcc06
      </querySession>
      <resultSet>
      <ns1:rows
      xmlns:ns1=" http://www.alfresco.org/ws/model/content/1.0">
      <ns1:rowIndex>0</ns1:rowIndex>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/system/1.0}store-protocol
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>workspace</ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}modifier
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>admin</ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}name
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>SampleContent.txt</ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/system/1.0}node-dbid
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>2121</ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}content
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>
      contentUrl=store://2007/7/12/13/42/05a414e3-306d-11dc-9782-6160ed7fcc06.bin|mimetype=text /plain|size=68|encoding=UTF-8|locale=en_US_
      </ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}modified
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>
      2007-07-12T13:42:51.895+02:00
      </ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}created
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>
      2007-07-12T13:42:51.286+02:00
      </ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/system/1.0}store-identifier
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>SpacesStore</ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/system/1.0}node-uuid
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>
      054727cd-306d-11dc-9782-6160ed7fcc06
      </ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}creator
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>admin</ns1:value>
      </ns1:columns>
      <ns1:columns>
      <ns1:name>
      { http://www.alfresco.org/model/content/1.0}path
      </ns1:name>
      <ns1:isMultiValue>false</ns1:isMultiValue>
      <ns1:value>
      /{ http://www.alfresco.org/model/application/1.0}company_home/{http://www.alfresco.org/model/ content/1.0}sample_folder/{http://www.alfresco.org/model/content/1.0}sample_content
      </ns1:value>
      </ns1:columns>
      <ns1:score>0.38761</ns1:score>
      <ns1:node>
      <ns1:id>
      054727cd-306d-11dc-9782-6160ed7fcc06
      </ns1:id>
      <ns1:type>
      { http://www.alfresco.org/model/content/1.0}content
      </ns1:type>
      </ns1:node>
      </ns1:rows>
      <ns2:totalRowCount
      xmlns:ns2=" http://www.alfresco.org/ws/model/content/1.0">
      1
      </ns2:totalRowCount>
      </resultSet>
      </queryReturn>
      </queryResponse>
      </soapenv:Body>
      </soapenv:Envelope>