3 ms·
That argument never made sense: " old readers will consider messages without this field to be incomplete and may reject or drop them unintentionally." That me
by gohrt 12y ago
That argument never made sense:
" old readers will consider messages without this field to be incomplete and may reject or drop them unintentionally."
That means the old readers -- the ones that are expecting required fields, can't accept new messages. That's good! The readers don't know how to read the new messages! The readers need to be updated to a new version before they can correctly start reading new version of the schema.
- kentonv 12y agoYeah, the problem is that because "required" is checked at the protobuf parser layer, it will be enforced whether or not the application itself actually depends on that field being present. In practice this tends to escalate minor bugs into full outages. Like, there have actually been outages in Google Search, Gmail, and others that wouldn't have happened if all required fields were treated as optional instead. I've written more about this here: https://kentonv.github.io/capnproto/faq.html#how_do_i_make_a_field_required_like_in_protocol_buffers https://kentonv.github.io/capnproto/faq.html#how_do_i_make_a...