3

I spent the whole damn day trying to setup grpc-web, but this protocol is documented so damn poorly!

You manage to set grpc up for one language and it’s all cool, then you stupidly think that you are free to reuse the compiler you used for the nodejs version for your frontend part but nope! Our web module is now deprecated, please use this module instead!

“Ah yes just clone the repo and check out (…) and you can also check this link whic is in no way highlighted in the middle of a wall of text (…)”

*checking the other page*
Ah yes you need to install a package available only on your unix machine (great! Screw the devs in my team who use windows I guess, they’ll be happy to hear this!) and don’t forget to clone this repo to build your own plugin! And by that I ofc mean to compile it on your own!

- compiler error
After digging for an hour you find a requirement in an obscure issue opened and closed cause “ah yes we have a dependency not stated anywhere” *close issue and never add it to the project*

Fine, fine I can survive this bs

- another compiler error, no solution found after 2 hours

Honestly? Why the fuck do I need to compile this stuff? Just give me a damn npm package I can use? Goddamn it’s just transpiling, you don’t need access to my OS! (Aside for fs to save the files, and which btw is accessible via nodejs)

Now, I COULD download the latest realease as a precompiled, but… honestly?
I give up, I’ll do some shitty rest apis cause the customer’s not paying me enough for even THINKING to go trough this shit again when they’ll ask an iOS app. Or having colleagues asking me to help them understand how to do it.

Side note: also add typescript support to the web-code-generation ffs! Why does node have it and web don’t?

Comments
  • 3
    https://github.com/harmony-developm...

    Disclaimer: Didn't work with it, but afaik the author's had the same fun with GRPC which was the reason they created their own. So might be completely fuckity for your use case, but hey: It's just a link, why not have a look?
  • 0
    Remind me why are you using Grpc?
    Plain CRUD/json not good enough?
  • 2
    @magicMirror mostly cause it reduces the amount of data during the communication and because the support for data streams is great!

    And cause I foolishly believed that they improved the setup part in these years.
  • 3
    @piratefox
    I hope you are dealing with 1kk messages daily to justify the grpc route.
    Grpc is really good for reducing communications/processing overheads for server and client, at specific cost - size limits, and protocol structure changes.
    setting it up can be a pain, especilly when you need to use plugins. The best approach I found to solve the generation problems is to:
    1. Generate once, using a single good setup (automation). Push to git. Pull to all devs. in case of proto changes, repeat the process.
    2. Generate the protos in a docker image based on linux, or a dedicated linux vm/actual machine. rsync the generated code to your local dev env.
    The docker approach is better.
  • 0
    @magicMirror not that many, but the devices are low performance and the network is tight!

    I agree with point 1&2, they are what I did, automation ftw!
Add Comment