Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
ASP.NET web site (not regular project) fails to find gRPC native binaries #12570
It will fail when it can't load the native library, which won't have been copied to the bin directory.
I know very little about "web site" projects, unfortunately - there's no project file, just a packages.config.
referenced this issue
Sep 14, 2017
I've just tried this with System.Data.Sqlite and seen the same effect. Their advice is "you need the native library on the path". I don't think we probe the path at the moment, which may be one option - another would be to allow an environment variable to specify where to find the DLL. Or just not support this scenario, potentially. (Ultimately, the support for native libraries in NuGet packages leaves something to be desired, but we need to work around that as best we can.)
I am facing this issue as well. I am working in a Proof of Concept to communicate code from a Website project to .NET Core 2 microservices (yeah I know, messy way but you know how Product Teams work with R&D teams and this is our only possibility to refactor our old code in microservices)
The workaround I'm aware of (assuming it's actually the same error - it's not immediately clear that it is) is to write code to copy the plugin into the bin directory before you make any gRPC calls.
But it sounds like there's probably nothing we can do about the nuget installation for the package not doing this itself - I suspect that Website projects just don't perform the right steps here :(
It fails also trying to load the native DLLs on path, it is the same that trying to copy them to Bin folder.
I will give RabbitMQ a try to communicate our website project with .NET Core 2 microservices. I wanted to use gRPC but it can't be possible with this kind of website projects.
Anyway thank you Jon for the help and for finding out this issue.