테스트 서버에 배포 한 WCF 서비스가 있습니다. 내 테스트 프로젝트에 사용하려고 내가 참조를 추가하고 난 내가 WSDL 문서를 포함하도록 내 서비스 프로젝트에 wsdlextras를 추가하기 전에 작업 내 테스트 응용 프로그램을 가지고이 오류를WCF- 문서를 이해했지만 처리 할 수 없습니다.
The document was understood, but it could not be processed.
- The WSDL document contains links that could not be resolved.
- There was an error downloading 'http://localhost:8731/somewhere.nowhere.com/service1/?xsd=xsd2'.
- Unable to connect to remote server
- No connection could be made because the target machine actively refused it
Metadata contains a reference that cannot be resolved: 'http://192.1.1.1/TestService/somewhere.nowhere.com.svc?wsdl'.
Content Type application/soap+xml; charset=utf-8 was not supported by service . The client and service bindings may be mismatched.
The remote server returned an error: (415) Cannot process the message because the content type 'application/soap+xml; charset=utf-8' was not the expected type 'text/xml; charset=utf-8'..
If the service is defined in the current solution, try building the solution and adding the service reference again.
를 얻을. 일을 해결하기 위해
<wsdl:types>
<xsd:schema targetNamespace="http://tempuri.org/Imports">
<xsd:import schemaLocation="http://localhost:8731/somewhere.nowhere.com/?xsd=xsd2" namespace="http://tempuri.org/"/>
<xsd:import schemaLocation="http://localhost:8731/somewhere.nowhere.com/?xsd=xsd1" namespace="http://schemas.datacontract.org/2004/07/TestService"/>
<xsd:import schemaLocation="http://localhost:8731/somewhere.nowhere.com/?xsd=xsd0" namespace="http://schemas.microsoft.com/2003/10/Serialization/"/>
<xsd:import schemaLocation="http://localhost:8731/somewhere.nowhere.com/?xsd=xsd3" namespace="http://schemas.microsoft.com/2003/10/Serialization/Arrays"/>
</xsd:schema>
</wsdl:types>
시도 :
이
내 WSDL의 스키마입니다 내가 모두가 mmatch 내 스키마에 내<host>
<baseAddresses>
<add baseAddress />
</baseAddresses>
</host>
그래서 내 주소를 변경했습니다. 내 테스트 프로젝트에서 내 서비스 참조를 업데이트 할 수는 있지만 wcf 서비스에서 노출 된 메소드를 볼 수는 없습니다.
내 서비스는 Windows 2003에서 배포하고 내 테스트 응용 프로그램은 그것이 가져온 XSD 파일 xsd2을 찾을 수없는 경우로 보이는 오류 메시지에서뿐만 아니라
192.1.1.1로 핑을 시도해보십시오. 결과가 나타나면 192.1.1.1 8731 명령을 사용하여 서버에 연결했는지, 방화벽이 연결을 차단했는지, 비스타에 서버를 배포하고 있는지 확인하십시오. –