我使用SUDS调用SOAP,代码如下:
client = Client("https://xyz.rwth.de/SecuredDataService/SecuredData?wsdl",location="https://xyz.rwth.de/SecuredDataService/SecuredData",cache=None)
对于HTTP请求,类似于上述代码的请求可以工作(上面的请求中没有位置部分和正确的HTTP URL),但是对于HTTPS,它失败并给出以下错误。在
DEBUG:suds.wsdl:reading wsdl at: https://xyz.rwth.de/SecuredDataService/SecuredData?wsdl ...
DEBUG:suds.xsd.sxbasic:Import:0x1025f5710, importing ns="http://secured.services.xyz123.org/", location="http://xyz.rwth.de:7070/SecuredDataService/SecuredData?xsd=1"
DEBUG:suds.transport.http:opening (http://xyz.rwth.de:7070/SecuredDataService/SecuredData?xsd=1)
ERROR:django.request:Internal Server Error: /XYZ12/index.html/
我得到了urlopen error [Errno 60] Operation timed out
基本上,日志文件显示location
参数没有被使用,而是使用了WSDL文件中指定的位置(即:http://xyz.rwth.de:7070/SecuredDataService/SecuredData?xsd=1)。为什么是这样,即使SUDS文档清楚地声明:location: This overrides the service port address URL defined in the WSDL.
?在
编辑:在添加cache=None
之后,将调用正确的位置,并在日志文件中打印整个WSDL。但是,在这之后,相同的错误(如上所述)会在日志文件中打印出来。在
目前没有回答
相关问题 更多 >
编程相关推荐