简体   繁体   中英

Are there any c# .Net Framework projects that can provide callbacks/responses to my .Net Core project?

I have a .Net Core API project (Angular front end) and it is missing certain libraries that are part of .Net Framework. So I need to have a project I can call from my .Net Core project to run some .Net Framework code. But I need to have callbacks/responses from the .Net Framework project that I can read in my .Net Core app so I know what's going on.

What's the best project type to allow communication between the two apps that will give me the responses (callbacks) I need? ex. success, error, etc

I could create a simple console app but then I'd be listening to the console output, right? Seems like there would be better options.

UPDATE - to be more specific - I want to call a web service (WCF). The web service is for documents to be uploaded. .Net Core doesn't support MTOM, which is something that is needed to make the call to the service. I can't seem to be able to make connection because of "the difference in libraries"? between the client (me) and the server(them). So I thought creating a .Net Framework project that I know will work and calling it from my .Net Core project is the only current solution?

I would just create a .NET web api project and have the .Net Core project call it using HTTP requests. Basically the the core project would act as a proxy in that it would act as a http client to the .NET webapi project when the special libraries are needed.

The same model has worked many times for me. Like when we used proprietary dlls that are not certified for core yet. Angular calls core controller, core controller proxies request to .NET controller using http request.

Resource on httpclient in core: https://docs.microsoft.com/en-us/aspnet/core/fundamentals/http-requests?view=aspnetcore-3.1

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM