I am trying to migrate some server code from .Net 4.7 to .Net Core 3.1 so we can run on a Linux host.
There are two connected services using SOAP. One has ported with zero changes but other has errors when importing using the WSDL file:
http://uat.risc.enexusrental.co.uk/SOAP/IndividualService.php?wsdl
I'm not a SOAP expert and have only ever used the code generated by importing WSDL files so the errors don't mean a lot to me.
Cannot import wsdl:port Detail: There was an error importing a wsdl:binding that the wsdl:port is dependent on. XPath to wsdl:binding: wsdl:definitions[@targetNamespace='http://uat.risc.enexusrental.co.uk']/wsdl:binding[@name='IndividualServiceHttpPost'] XPath to Error Source: //wsdl:definitions[@targetNamespace='http://uat.risc.enexusrental.co.uk']/wsdl:service[@name='IndividualService']/wsdl:port[@name='IndividualServiceHttpPost'] Cannot import wsdl:binding Detail: The required WSDL extension element 'binding' from namespace 'http://schemas.xmlsoap.org/wsdl/http/' was not handled. XPath to Error Source: //wsdl:definitions[@targetNamespace='http://uat.risc.enexusrental.co.uk']/wsdl:binding[@name='IndividualServiceHttpPost'] Cannot import wsdl:port Detail: There was an error importing a wsdl:binding that the wsdl:port is dependent on. XPath to wsdl:binding: //wsdl:definitions[@targetNamespace='http://uat.risc.enexusrental.co.uk']/wsdl:binding[@name='IndividualServiceHttpGet'] XPath to Error Source: //wsdl:definitions[@targetNamespace='http://uat.risc.enexusrental.co.uk']/wsdl:service[@name='IndividualService']/wsdl:port[@name='IndividualServiceHttpGet'] Cannot import wsdl:binding Detail: The required WSDL extension element 'binding' from namespace 'http://schemas.xmlsoap.org/wsdl/http/' was not handled. XPath to Error Source: //wsdl:definitions[@targetNamespace='http://uat.risc.enexusrental.co.uk']/wsdl:binding[@name='IndividualServiceHttpGet']
To simplify debugging I created simple command line apps, one for .Net 4.7 and the other Core 3.1.
Importing worked perfectly for the .Net 4.7 and I can call the service (as expected).
Importing for Core 3.1 gives the errors as above and when calling the client initialization it returns an error of:
Client.Channel = 'Client.Channel' threw an exception of type 'System.ServiceModel.CommunicationObjectFaultedException'
I get the same errors when importing using svcutil.exe manually.
After 3 days Googling I am no further on as each problem seems to be different and none of the solutions work.
Would someone be kind enough to explain what these errors actually mean (I'm not a SOAP expert) and, if possible, what I sort of things I need to do to work around them?
/wsdl:binding[@name='IndividualServiceHttpGet']
– Gusman