Our team at Storj is building a decentralized cloud object storage and when we decided to build it using Go, we thought we’d also utilize gRPC for p

How We Built an Open Source Drop-In Replacement for gRPC

submited by
Style Pass
2021-05-26 20:00:11

Our team at Storj is building a decentralized cloud object storage and when we decided to build it using Go, we thought we’d also utilize gRPC for peer-to-peer remote procedure calls in client/server interactions. gRPC is designed for environments like the one we are building at Storj. It connects services together with easy code generation, robust wire protocols, and low overhead. Also, gRPC has some serious clout. It is open source and widely used by companies in the cloud — including Cockroach Labs, Docker, Dropbox, IBM, Netflix, Square, Wikipedia, and many more companies you’ve likely heard of.

However, we discovered that gRPC needed improvements — at least for us. How could this be? After all, gRPC was built by Google and it’s used by all the “cool” companies. But for next-generation, decentralized architectures, it wasn’t for us. So after trying to make gRPC work for us for too long, we looked for an alternative.

When we started looking at our object storage product to identify performance improvement opportunities, we found that we were spending a lot of time fighting gRPC. gRPC is monolithic and not very modular; it has lots of feature bloat. For example, instead of providing a modular mechanism to establish an underlying socket transport, gRPC wants to own the entire dialing system and has spawned a dizzying amount of complexity in connection state management. When it came to debugging at 2 a.m., we wanted a much simpler state machine.

Leave a Comment