When writing a .proto file for gRPC I have noticed that I can either.
1) Include all my messages (requests and responses) inside one .proto file along with all the rpcs.
2) Write each rpc in its own .proto file.
I can see that when I have two rpcs that access the same messages it is more convenient to write the protocol buffers in the same file. However I would prefer to split them up when possible to take the more modular approach.
My question is, ignoring preference is there any efficiency difference between these two approaches? Also any info on convention here would be appreciated.
NOTE: I am using gRPC (C++ and Java) I don't know if the language implementation has something to do with the answer.