How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

1-1-1 Best Practice

calendar_today January 1, 0001 person domain protobuf

The “1-1-1” best practice advocates structuring definitions with one top-level entity (message, enum, or extension) per .proto file, corresponding to a single proto_library build rule. This approach promotes small, modular proto definitions. Key benefits include simplified refactoring, potentially improved build times, and smaller binary sizes due to minimized transitive dependencies. Rationale The 1-1-1 best practice is to keep every proto_library and .proto file as small as is reasonable, with the ideal being:

open_in_new Read original post