protocolbuffers/protobuf
View on GitHub ↗ ★ 72,148 C++
Protocol Buffers - Google's data interchange format
124 mentions on Hacker News by 89 people: 11 stories, 113 comments · first 2014-12-15 · latest 2026-10-09
20082026
-
…decisions made in protobuf, or if it's just one less bad tradeoff among several bad ones. [1]: https://github.com/protocolbuffers/protobuf/blob/e9360dfa53f...
comment by sleepydog · 2021-03-31 · in Golang: Know Your 'Nil' -
…also met with much opposition internally, and recently changed as of v3.12 (released last year). https://github.com/protocolbuffers/protobuf/blob/master/docs... https://github.com/protocolbuffers/protobuf/releases/tag/v3....
comment by vitus · 2021-03-30 · in Golang: Know Your 'Nil' -
Oh, I see now - https://github.com/protocolbuffers/protobuf/releases/tag/v3.... (General) - I wasn't aware of that as I think I've started using proto3 after that version. Good to know.
comment by malkia · 2021-03-15 · in REST vs GraphQL vs gRPC -
…implementation (or something similar) the last time I looked at protobuf. We sort of do actually: https://github.com/protocolbuffers/protobuf/blob/master/src/... The internal version of protobuf lets you switch individual string fields to…
comment by haberman · 2020-12-30 · in Don't Use Protobuf for Telemetry -
(More) permanent link for those reading this a few years later. https://github.com/protocolbuffers/protobuf/blob/5a7a4a52a79...
comment by scaladev · 2020-11-24 · in “To be safe allocate 5 bytes more than you need” -
The latest optimized version of the protobuf parser does a remarkably similar thing: https://github.com/protocolbuffers/protobuf/blob/master/src/... Protobufs are full of varints, and we want to perform only one bounds-check per field. So…
comment by haberman · 2020-11-23 · in “To be safe allocate 5 bytes more than you need” -
…and has no formal spec, and this appears to be intentional, with no plans for improvement: https://github.com/protocolbuffers/protobuf/issues/3755 .
comment by atombender · 2020-10-04 · in NestedText, a nice alternative to JSON, YAML, TOML -
…C++ (as linked), Java https://developers.google.com/protocol-buffers/docs/referenc... , and Python https://github.com/protocolbuffers/protobuf/blob/master/pyth... I think the Protobuf spec focuses on the binary serialization - the text…
comment by vii · 2020-07-23 · in Amazon Ion -
…open issue [1] tracking the possibility of making it available in the open source version too. [1] https://github.com/protocolbuffers/protobuf/issues/1896
comment by quietbritishjim · 2020-06-21 · in FlexBuffers -
…use something like http://jsonlines.org/ (i.e. JSON messages separated by newline characters), or https://github.com/protocolbuffers/protobuf if it's more performance-critical.
comment by jstanley · 2020-05-15 · in What developers should know about TCP -
…it doesn't seem to really match this description or enforce a hermetic seal. What am I missing? [1] https://github.com/protocolbuffers/protobuf
comment by keithwinstein · 2020-05-14 · in Building Uber’s Go Monorepo with Bazel -
I like the way how google does it with StatusOr and some status macros https://github.com/protocolbuffers/protobuf/blob/master/src/... https://github.com/protocolbuffers/protobuf/blob/master/src/...
comment by thisgoodlife · 2020-04-22 · in Why should I have written ZeroMQ in C, not C++ (2012) -
It exists in C++ too: https://github.com/protocolbuffers/protobuf/blob/master/src/...
comment by haberman · 2020-03-10 · in MessagePack: like JSON, but fast and small -
…with Cap'n'proto but apparently Google already has a zero-copy API for Protocol Buffers internally: https://github.com/protocolbuffers/protobuf/issues/1896
comment by Youden · 2020-03-08 · in We have to talk about this Python, Gunicorn, Gevent thing -
…these fields with a comment explaining the apparently pointless wrapper. Google themselves provide https://github.com/protocolbuffers/protobuf/blob/master/src/... to deal with this situation. Quoted from the documentation: > Wrappers for…
comment by gen220 · 2020-01-31 · in Jepsen: Etcd 3.4.3 -
You can implement emptiness with the wrapper message types, e.g. StringValue: https://github.com/protocolbuffers/protobuf/blob/master/src/... and sometimes defining your own, e.g. nullable lists. It's not elegant, but it is simple.
comment by gabetax · 2020-01-30 · in Jepsen: Etcd 3.4.3 -
https://github.com/protocolbuffers/protobuf/issues/1896 Ok some of the things I said couldn't be done, can be done, but it's situational
comment by tlarkworthy · 2019-12-26 · in Protobuffers Are Wrong -
…one has to use convention _in every single class_ to determine basic things like PATCH semantics ( https://github.com/protocolbuffers/protobuf/issues/359 ). This makes it impossible to treat protobuf as a general data format and requires…
comment by abernard1 · 2019-12-24 · in Protobuffers Are Wrong -
> there is no proto2 library for C#! Looks like that's getting fixed! https://github.com/protocolbuffers/protobuf/blob/master/docs... https://github.com/protocolbuffers/protobuf/pulls?q=is%3Apr+...
comment by kentonv · 2019-12-24 · in Protobuffers Are Wrong -
…specify a dang top-level-package in the emitted _pb2.py and let me wrangle it with setup.py? [0] - https://github.com/protocolbuffers/protobuf/issues/90 [1] - https://github.com/protocolbuffers/protobuf/issues/1491
comment by kortex · 2019-12-24 · in Protobuffers Are Wrong -
…as explicit (actually often moreso, since its more difficult to forget an error condition) [1]: https://github.com/protocolbuffers/protobuf/blob/d0f91c863ae...
comment by joshuamorton · 2019-10-21 · in Python at Scale: Strict Modules -
…to use exceptions in C++. Google doesn't, for example. Errors are reported with StatusOr<> like so: https://github.com/protocolbuffers/protobuf/blob/master/src/...
comment by m0zg · 2019-08-30 · in Linux kernel drivers in Rust might become an option in the future -
…is similar to this one in that it makes guesses and then uses strtod() to check them. (...) https://github.com/protocolbuffers/protobuf/blob/ed4321d1cb3...
comment by coldtea · 2019-08-28 · in Python rounds float values by converting them to string and then back -
…that's similar to the RETURN_IF_ERROR that's common in Google C++ code (for example, in protobuf: https://github.com/protocolbuffers/protobuf/blob/master/src/... )
comment by cbhl · 2019-07-03 · in An Open Letter to the Go Team About Try -
…A really large amount of work has gone into protobuf C++ performance in the last 3 years or so. 1: https://github.com/protocolbuffers/protobuf/blob/master/src/...
comment by shereadsthenews · 2019-06-24 · in Fast key-value stores: An idea whose time has come and gone -
…the reader that a given function call can fail. This seems nice, and I would definitely use it. [1] https://github.com/protocolbuffers/protobuf/blob/master/src/...
comment by alexhutcheson · 2019-06-05 · in Proposal: A built-in Go error check function, try -
…removed due to the challenges it introduces in designing backwards-compatible API changes[1]. [1] https://github.com/protocolbuffers/protobuf/issues/2497#issu...
comment by ntenenz · 2019-05-27 · in Why We’re Switching to gRPC -
…a suitable type signature. [0] https://capnproto.org/faq.html#how-do-i-make-a-field-require... [1] https://github.com/protocolbuffers/protobuf/issues/2497#issu...
comment by pacala · 2019-02-19 · in Why I Prefer Dynamic Typing Over Static Typing (2017) -
…but there is a reason that "required" fields were taken out in proto3). From the source code: https://github.com/protocolbuffers/protobuf/blob/master/src/... // An UnknownFieldSet contains fields that were encountered while parsing a //…
comment by joatmon-snoo · 2019-01-08 · in SQL Is No Excuse to Avoid DevOps -
…the package name). [1] https://stackoverflow.com/questions/18735609/the-path-in-pro... [2] https://github.com/protocolbuffers/protobuf/issues/723#issue...
comment by quietbritishjim · 2018-12-18 · in BloomRPC: GUI Client for GRPC Services -
…[3]. He lurks around here :) [0] https://plus.google.com/+KentonVarda/posts/TSDhe5CvaFe [1] https://github.com/protocolbuffers/protobuf [2] https://capnproto.org [3] https://sandstorm.io
comment by AceJohnny2 · 2018-12-04 · in The Friendship That Made Google Huge -
…lower-quality than internal Google code, which shocked me. I've found memory errors in protobuf ( https://github.com/protocolbuffers/protobuf/issues/3752 ), all sorts of wacky stuff in Bazel, and every day I wonder why go-protobuf doesn't…
comment by jmillikin · 2018-10-11 · in Ask HN: Ex-FAANG developers, where are you now and why? -
> No one said that all fields should be optional As of protobuf v3, all fields must be optional. https://github.com/protocolbuffers/protobuf/issues/2497
comment by slavik81 · 2018-10-11 · in Arguing against using protobuffers -
…If T is a scalar, you get to use one of the WKTs. See this GitHub issue for more context: https://github.com/protocolbuffers/protobuf/issues/1606 I work with data where most attributes outside of the attributes that compose the key…
comment by deathanatos · 2018-10-11 · in Arguing against using protobuffers -
…files and mkmf creates a Makefile that builds against the correct headers with the correct flags: https://github.com/google/protobuf/blob/master/ruby/ext/goog... This tool knows about C/C++. It sadly doesn't know about Rust.
comment by haberman · 2018-07-20 · in The future of WebAssembly – A look at upcoming features and proposals -
…dtoa(). And so that's how the Protocol Buffers library deals with numbers when writing TextFormat: https://github.com/google/protobuf/blob/ed4321d1cb3319998411... But the bigger lesson for me was: Transmitting floating-point numbers in…
comment by kentonv · 2018-06-11 · in How to Print Floating-Point Numbers Accurately (1990) [pdf] -
…any new parser through the conformance tests; I created these to exercise some of the edge cases. https://github.com/google/protobuf/tree/master/conformance Here are some of the quirks of protobuf: - non-repeated fields can occur multiple…
comment by haberman · 2018-04-23 · in Parsing JSON is a Minefield -
…directory structure for all source files, including protos. Well, yes. You do... At Google. [1] https://github.com/google/protobuf/issues/881 [2] https://github.com/google/protobuf/issues/1491
comment by heavenlyblue · 2018-03-09 · in Relibc: C Library in Rust for Redox and Linux -
…fields. There was a change that made proto3 do this, and that has now (thankfully) been reversed. https://github.com/google/protobuf/issues/272#issuecomment-2...
comment by charleslmunger · 2018-02-11 · in The insane amount of backward compatibility in Google Maps -
> And JSON endpoints are a damn sight easier to debug and wireshark and all the rest. https://github.com/google/protobuf/issues/3303
comment by merb · 2018-01-26 · in gRPC-Go Engineering Practices -
…schema-less. The Any type is also designed for this sort of thing. Still clumsy, though. [1] https://github.com/google/protobuf/blob/master/src/google/pr...
comment by spenczar5 · 2018-01-16 · in Twirp: A new RPC framework for Go -
…fields can be ignored and "required fields are generally considered harmful", interesting read: https://github.com/google/protobuf/issues/2497
comment by ithkuil · 2017-12-11 · in Son: A minimal subset of JSON for machine-to-machine communication -
I don't follow what you are saying. Protobuf has a BUILD file: https://github.com/google/protobuf/blob/master/BUILD Do you mean something else? A GitHub issue might be a better place for this discussion.
comment by haberman · 2017-09-26 · in Abseil: C++ Common Libraries -
…develop. Another alternative is using something like protobuf [1] to define your data models. [1] https://github.com/google/protobuf
comment by rockostrich · 2017-07-27 · in Ruby on Rails is out: major coding bootcamp ditches it, due to waning interest -
…as google.protobuf.BoolValue instead of bool gives you that (same with the other primitive types: https://github.com/google/protobuf/blob/master/src/google/pr... ). But making primitive types never null aligns proto3 with most programming…
comment by euyyn · 2017-03-14 · in The Sandstorm Team Is Joining Cloudflare -
…not perfect. For instance, I was not able to build GzipInputStream and GzipOutputStream (see e.g. https://github.com/google/protobuf/issues/2365 ).
comment by petercerno · 2017-03-14 · in Buck – A build system developed and used by Facebook -
Google has StatusOr<T> for this purpose: https://github.com/google/protobuf/blob/master/src/google/pr...
comment by praptak · 2016-12-15 · in When noexcept? -
Protocol Buffers is not proprietary. It is open source under the BSD license. Here is the source code: github.com/google/protobuf. It is very much an open protocol, and anyone is free to write their own implementation of it. It is just a…
comment by int_handler · 2016-08-01 · in How to Avoid Being Called a Bozo When Producing XML (2005) -
…So I think this issue is worth discussing further, and I opened an issue on GitHub to track it: https://github.com/google/protobuf/issues/1890 Thanks for the feedback.
comment by haberman · 2016-07-29 · in Protocol Buffers v3.0.0 released -
https://github.com/google/protobuf/blob/master/src/google/pr...
comment by dyoo1979 · 2016-07-29 · in Protocol Buffers v3.0.0 released