I got feedback that DlcModuleList in src/system_api/dbus/update_engine/update_engine.proto and DlcParameters in src/system_api/dbus/update_engine/update_engine.proto should be merged into a single message. We had a discuss earlier today but no one has a strong opinion (since I'm the developer of both the APIs and protobufs, I might tend to be biased against one way or the other) so I'm posting here to gather more feedback.
Here are a few points from myself and the discussion we just had among several team members. Feel free to provide more feedback and they are much appreciated.
Pros:
1. The two message (DlcModuleList, DlcParameters) look similar. One is a list of strings while the other is a list of strings plus a standalone string.
2. The two both serve the communication between dlcservice and update_engine.
3. In the case when both need to add identical field in both messages (not sure if common), we can save the effort to edit both.
4. In the future it’s easy to diverge into two protobuf if necessary. It’s unknown how difficult it is to unify them again after they diverge but I think there is no strong reason to unify them any more since they diverge for a reason.
5. One less *.proto file.
6. Easy (or hard) to maintain?
Cons:
1. The extra string has to be ignored for DlcModuleList and causes confusion.
2. More comments (multiplexing the same protobuf for 2 different API) are needed to dis-obfusticate the developers.
3. DlcModuleList and DlcParameters serve different APIs (GetInstalled vs AttemptInstall) for different services (dlcservice vs update_engine).
4. More diverges (expected but not sure atm) cause more severe 1 and 2.
6. Hard (or Easy) to maintain?
7. One more *.proto file.
Comment 1 by ahass...@chromium.org
, Nov 8