I have a C# grpc service that works fine if I call it from a .Net Core Console app...However, I get the following error if I try to call it from a .Net Core Webapi Project [Status(StatusCode=Unavailable, Detail="Connect Failed")]. The difference between the console app and the webapi app is that I am not creating the channel in the main method...I am instead creating it elsewhere...I have tried several different ways:
- In the startup class, and inject it as a dependency injection to a repository class to use it.
- Creating new instance in my repository class.
- Creating a new instance in my webapi controller.
But, all those methods result in the same error of: [Status(StatusCode=Unavailable, Detail="Connect Failed")]
Does anyone have any insight on how to get over this hurdle?...The big picture is a webapi .net core aggregation rest service, that will be calling underlying grpc services. Is that just not possible?
Thanks in advance,