خرید بک لینک

Vote count: 0

I'm currently trying to consume a C# WCF service with a PHP Client. The interface below defines all the operation my service has to implement.

[ServiceContract]
public interface IJobService
{

    [OperationContract]
    JobInfo addJob(RemoteFileInfo request);

    [OperationContract]
    JobInfo getJobByID(JobIDMessage jobIDMessage);

    [OperationContract]
    JobListInfo getAllJobs();

    [OperationContract]
    DownloadMessage DownloadFile(JobIDMessage jobIDMessage);

    [OperationContract]
    SuccessOrFailureMessage DeleteRemoteFile(JobIDMessage jobIDMessage);

}

I'm trying to use a PHP SOAP client to consume the different methods my webservice offers, and I can access them without any trouble using the code below:

define("WSDL", "http://localhost:55521/Services/JobService.svc?wsdl");
try 
{ 
    $service = new SoapClient(WSDL,array("trace" => 1, "exceptions" => 0));

    $service->getAllJobs();

    $string= $service->__getLastResponse();

    print_r($string);

} 
catch (SoapFault $exception)  
{ 
    var_dump($exception);  
}

The problem is, when I'm trying to read the response, PHP sens me back the following error :

'looks like we got no XML document'

I tried to trace the error as you can see In my php code, but it doesn't seem to retu useful information, because when I do that, I get the datas of my getAllJobs method !

--uuid:74db9360-ba2f-4895-bb36-88d0f3dad77c+id=33 Content-ID: Content-Transfer-Encoding: 8bit Content-Type: application/xop+xml;charset=utf-8;type="text/xml" 2912eeb7-5fec-429f-8e9b-2875cea14a2234551192102016-06-09T10:37:42.2568136292016-06-09T10:37:27.8522463ftp://localhost/transcode_uploads/Luc/LinkinPark-DontStay.au0.05234551192102016-06-09T11:46:07.759063510292016-06-09T11:45:55.8115507ftp://localhost/transcode_uploads/Luc/LinkinPark-DontStay.au0.0523079869402016-06-10T01:14:06.658839630292016-06-10T01:13:44.6595219ftp://localhost/transcode_uploads/regine/DjAssad-Addicted.ogg0.0625094920402016-06-10T01:18:30.490585530302016-06-10T01:18:21.8755862ftp://localhost/transcode_uploads/regine/DjAssad-Addicted.ac30.0625094920402016-06-10T01:22:12.057759430312016-06-10T01:22:03.7102454ftp://localhost/transcode_uploads/regine/DjAssad-Addicted.ac30.0625094920402016-06-10T01:24:18.922430830322016-06-10T01:23:27.4754129ftp://localhost/transcode_uploads/regine/DjAssad-Addicted.ac30.0625094920402016-06-10T01:28:11.395782830332016-06-10T01:28:02.6875516ftp://localhost/transcode_uploads/regine/DjAssad-Addicted.ac30.0621882545002016-06-10T15:11:44.013122740332016-06-10T15:11:35.293252ftp://localhost/transcode_uploads/Jeremy/small.ogg02281302515002016-06-10T15:13:55.834766740342016-06-10T15:13:45.5795116ftp://localhost/transcode_uploads/Jeremy/LinkinPark-BuItDown.flac0.06237007444692016-06-12T11:42:37.386370150332016-06-12T11:42:24.6186797ftp://localhost/transcode_uploads/Jacques/Afrojackft.Fais-Hey.au0.062 --uuid:74db9360-ba2f-4895-bb36-88d0f3dad77c+id=33--

Here is my webservice configuration:

<system.serviceModel>
<services>
  <service behaviorConfiguration="ServiceWithMetadata"          name="Transcode.Webservice.Services.JobService">
    <endpoint address="" binding="basicHttpBinding" bindingConfiguration="LargeFiles"
      contract="Transcode.Webservice.Services.IJobService" />
    <host>
      <timeouts openTimeout="00:05:00" />
    </host>
  </service>
</services>
<behaviors>
  <serviceBehaviors>
    <behavior name="ServiceWithMetadata">
      <serviceMetadata httpGetEnabled="true" />
      <serviceDebug includeExceptionDetailInFaults="false" />
    </behavior>
  </serviceBehaviors>
</behaviors>
<bindings>
  <basicHttpBinding>
    <binding name="LargeFiles" messageEncoding="Mtom" maxReceivedMessageSize="2147483647" maxBufferSize="2147483647" transferMode="Streamed">
      <readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
    </binding>
  </basicHttpBinding>
</bindings>

I'm really confused, and I can't find the problem, I don't know if it's WCF which doesn't do its job or if I did a mistake but I'm searching an answer since yesterday, and still got no clue abot what's happening ...

Please help me guys !

asked 3 mins ago

برچسب: نویسنده: استخدام کار تاريخ: يکشنبه 23 خرداد 1395 ساعت: 20:57

صفحه بندی