-
Notifications
You must be signed in to change notification settings - Fork 10.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
using grpc with webpack? #11435
Comments
There's a bigger problem with using webpack: gRPC uses a Node C++ addon that interfaces with low-level Node C APIs. It's not going to work except on Node. |
@slootzky We haven't yet released grpc-web which uses a different stack than grpc (due to browser limitation). Once grpc-web is available, we should consider making it deployable in Node (webpack etc). If you need early access to grpc-web, let me know. |
seems like it's also doesn't work on a nodejs Azure function |
This is a separate issue, i.e. making grpc calls from Azure functions. We should verify. |
@slootzky Can you elaborate? What problems did you experience when you tried to use gRPC in a Node.js Azure function? |
@murgatroid99 it's because azure functions runs over edgejs |
By the way, the code in |
@raviqqe totally agree , especially when things like prepack become more stable , I think runtime optimization is always more than welcome. |
Totally Agree. |
It seems to be impossible because of limitation of node-pre-gyp's API. |
this sucks....,. you broke my entire app with this bs... there is no way to use any google products with any serverless products now... how do i make these work? ?????????? i dont give two shits about anything but node but this does not work on node either so.... uhh... .yeah......
why would you close something that is clearly still a bug |
@bradennapier You can exclude |
Hey ,
using google's pubsub node client and it depends on grp which depends on node-pre-gyp.
when using webpack (for serverless functions) I get the following runtime error :
this comes from pre-bindings.js :
if (!existsSync(package_json_path)) { throw new Error("package.json does not exist at " + package_json_path); }
and this because in grpc_extensions.js is using __dirname and then relative path :
var binding_path = binary.find(path.resolve(path.join(__dirname, '../../../package.json')));
The text was updated successfully, but these errors were encountered: