C
C#3mo 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?
9 Replies
Unknown User
Unknown User3mo ago
Message Not Public
Sign In & Join Server To View
Apache
Apache3mo ago
The services themselves are not being touched. All I'm doing is migrating the API reference docs, from Umbraco, to OrchardCore, with a Blazor de-coupled front-end.
Unknown User
Unknown User3mo ago
Message Not Public
Sign In & Join Server To View
Apache
Apache3mo ago
The reference docs have code samples, and live demos. The live demos can use REST, that's fine.
Unknown User
Unknown User3mo ago
Message Not Public
Sign In & Join Server To View
Apache
Apache3mo ago
But the code samples are programmatically built from the SOAP objects. There's a System.Web.Services.Description NuGet package, but it doesn't contain ServiceDescriptionImporter, only ServiceDescription.
Unknown User
Unknown User3mo ago
Message Not Public
Sign In & Join Server To View
reflectronic
reflectronic3mo ago
so… the code for ServiceDescriptionImporter is online and licensed appropriately for use https://github.com/microsoft/referencesource/blob/master/System.Web.Services/System/Web/Services/Description/ServiceDescriptionImporter.cs i haven’t looked to see how much the implementation relies on internal classes to WCF if it doesn’t, then you can just copy it into your project if it does, you’ll have to fork WCF, add the code in, and build a private version of System.ServiceModel.* to use
Apache
Apache3mo ago
The answer to this question is pretty much exactly what we are doing now, and need to move away from: https://stackoverflow.com/questions/38482849/generating-proxy-class-from-wsdl-on-the-fly
Stack Overflow
Generating proxy class from WSDL on the fly?
I'm currently working a Windows Service which when started takes a load of scripts and compiles them for running on a schedule, however some of these scripts need to access ASMX web services. My
Want results from more Discord servers?
Add your server
More Posts
✅ How do i learn C#, as a Junior Frontend Developer who have used JavaScript and React, TailwindCSSHello internet strangers, I want to learn C#, Where is the best place for me to learn it, as a Juni✅ XmlReader generic MapperHello 👋 . I am trying to create generic mapper for my project, that is using XmlReader. All my XML Disable Blazor NavLinkIs there any way to disable a NavLink in Blazor? While my application is doing some long calculationAsp.net Login and SignupI have form where user can login or sign up but I need help with form saving the credentials to data✅ C# + raylib + freebsdHi All, I'm running FreeBSD 14 Release, dotnet 8.0 compiled from Ports and Raylib 5.0 downloaded f✅ Setting Foreign key as Primary Key (EF Core)I want to set a foreign key as my primary key in a link table im using. How would I do this in EF CoWinform my button to reset my picturebox and fill it in with a new generated image is not workinghttps://hatebin.com/cslhmvmnya - my code Lines 121-124 is the methos to reset the picturebox but ImVS Project config questions1. Is it bad to enable "Place solution and project in the same folder"? It sounds neater to me but w(Blazor) I'm having trouble accessing a variable inside a parent component.I'm trying to access a simple bool in a parent component that shows when my side bar has been collap✅ There is already an open DataReader associated with this Command which must be closed firstI'm currently developing a Point Of Sale software in winforms c#. While working on cash management m