C#C
C#2y ago
Apache

Migrating WSDL imports via ServiceDescriptionImporter from Framework to Core

I'm writing documentation website for a backwards compatible API. I'm migrating code from .NET Framework 4.7.2, to .NET8.

In
net472
, we get the results of any given WSDL URL, read it into a
System.Web.Services.Description.ServiceDescription
, check if there are any warnings with a
System.Web.Services.Description.ServiceDescriptionImporter
, create an assembly in memory, with
Microsoft.CSharp.CSharpCodeProvider
, and then read the
System.Type
from the assembly via reflection.

A lot of this has been ripped out of BCL in Core. Both SOAP and WCF are both depreciated, but a lot of our clients still use the SOAP services on legacy projects; so we need to keep them up, and documented. But, we also need to move on tech-stack wise. So, I'm wondering what the options are. Ideally, some wonderful person will have created a NuGet library that would wrap all of this up, and make it all magically work within
net8.0
. But, failing the coming of a saviour, how else would it be possible to programmatically resolve a
System.Type
from any given WSDL URL?
Was this page helpful?