Software Alternatives, Accelerators & Startups

GraphQL Ruby VS Protobuf

Compare GraphQL Ruby VS Protobuf and see what are their differences

GraphQL Ruby logo GraphQL Ruby

Application and Data, Languages & Frameworks, and Query Languages

Protobuf logo Protobuf

Protocol buffers are a language-neutral, platform-neutral extensible mechanism for serializing structured data.
  • GraphQL Ruby Landing page
    Landing page //
    2020-02-21
  • Protobuf Landing page
    Landing page //
    2023-08-29

GraphQL Ruby features and specs

No features have been listed yet.

Protobuf features and specs

  • Efficient Serialization
    Protobuf is known for its high efficiency in serializing structured data. It is faster and produces smaller size messages compared to JSON or XML, making it ideal for bandwidth-limited and resource-constrained environments.
  • Language Support
    Protobuf supports multiple programming languages including Java, C++, Python, Ruby, and Go. This makes it versatile and useful in heterogeneous environments.
  • Versioning Support
    It natively supports schema evolution without breaking existing implementations. Fields can be added or removed over time, ensuring backward and forward compatibility.
  • Type Safety
    Being a strongly typed data format, Protobuf ensures that data is correctly typed across different systems, preventing serialization and deserialization errors common with loosely typed formats.

Possible disadvantages of Protobuf

  • Learning Curve
    Protobuf requires learning and understanding its schema definitions and compiler usage, which might be a challenge for new developers.
  • Lack of Human Readability
    Serialized Protobuf data is in a binary format, making it less readable and debuggable compared to JSON or XML without specialized tools.
  • Limited Built-in Support for Complex Data Types
    By default, Protobuf does not provide comprehensive support for handling complex data types like maps or unions compared to some other data serialization formats, requiring workarounds.
  • Tooling Requirement
    Using Protobuf necessitates a compilation step where `.proto` files are converted into code, requiring additional tooling and build system integration.

GraphQL Ruby videos

No GraphQL Ruby videos yet. You could help us improve this page by suggesting one.

Add video

Protobuf videos

StreamBerry, part 2 : introduction to Google ProtoBuf

Category Popularity

0-100% (relative to GraphQL Ruby and Protobuf)
Developer Tools
27 27%
73% 73
Configuration Management
0 0%
100% 100
Software Development
100 100%
0% 0
Mobile Apps
0 0%
100% 100

User comments

Share your experience with using GraphQL Ruby and Protobuf. For example, how are they different and which one is better?
Log in or Post with

Social recommendations and mentions

Based on our record, Protobuf should be more popular than GraphQL Ruby. It has been mentiond 83 times since March 2021. We are tracking product recommendations and mentions on various public social media platforms and blogs. They can help you identify which product is more popular and what people think of it.

GraphQL Ruby mentions (14)

  • The GraphQL N+1 Problem and SQL Window Functions
    In our Rails application, we use the popular graphql Ruby gem to resolve GraphQL queries. When used naively, it essentially resolves queries as a depth-first tree traversal, which leads to the N+1 problem in GraphQL. - Source: dev.to / over 2 years ago
  • Rookie question regarding Active Record and creating an empty array as a class variable
    If you're comfortable on the react/client side with graphql, I'd highly recommend plugging in https://graphql-ruby.org/. Source: over 2 years ago
  • GraphQL APIs in Rails
    The next step is to add the GraphQL gem to our Gemfile; you can visit its page, graphql-ruby, for more details; now, open your Gemfile and add this line:. - Source: dev.to / about 3 years ago
  • Anyone here turned their rails app into an API?
    If you do go the API route though, strongly consider using GraphQL with the (graphql-ruby)[https://graphql-ruby.org/] gem. Source: about 3 years ago
  • How to work with an external front-end developer?
    GraphQL saves you time designing versioned REST endpoints. It self documents. Documentation isn't optional for serious web development so this is a huge win. The rails gems have gotten really good at picking up associations as well since I looked into a couple years ago. https://graphql-ruby.org. Source: over 3 years ago
View more

Protobuf mentions (83)

  • JSON vs Protocol Buffers vs FlatBuffers: A Deep Dive
    Protocol Buffers, developed by Google, is a compact and efficient binary serialization format designed for high-performance data exchange. - Source: dev.to / about 2 months ago
  • Developing games on and for Mac and Linux
    Protocol Buffers: https://developers.google.com/protocol-buffers. - Source: dev.to / about 2 years ago
  • Adding Codable conformance to Union with Metaprogramming
    ProtocolBuffers’ OneOf message addresses the case of having a message with many fields where at most one field will be set at the same time. - Source: dev.to / over 2 years ago
  • Logcat is awful. What would you improve?
    That's definitely the bigger thing. I think something like Protocol Buffers (Protobuf) is what you're looking for there. Output the data and consume it by something that can handle the analysis. Source: over 2 years ago
  • Bitcoin is the "narrow waist" of internet-based value
    These protocols prevent an O(N x M) explosion of code that have to solve for many cases. For example, since JSON is an almost ubiquitous format for wire transfer (although other things do exist like protobufs), if I had N data formats that I want to serialize, I only need to write N serializers/deserializers (SerDes). If there was no such narrow waist and there were M alternatives to JSON in wide usage, I would... Source: over 2 years ago
View more

What are some alternatives?

When comparing GraphQL Ruby and Protobuf, you can also consider the following products

GraphQL - GraphQL is a data query language and runtime to request and deliver data to mobile and web apps.

gRPC - Application and Data, Languages & Frameworks, Remote Procedure Call (RPC), and Service Discovery

Messagepack - An efficient binary serialization format.

JSON - (JavaScript Object Notation) is a lightweight data-interchange format

Apache Thrift - An interface definition language and communication protocol for creating cross-language services.

YAML - YAML 1.2 --- YAML: YAML Ain't Markup Language