Merge lp://qastaging/~albaguirre/mir/server-improve-abi-compat-with-mirprotobuf into lp://qastaging/mir
Status: | Work in progress |
---|---|
Proposed branch: | lp://qastaging/~albaguirre/mir/server-improve-abi-compat-with-mirprotobuf |
Merge into: | lp://qastaging/mir |
Diff against target: |
748 lines (+127/-122) 13 files modified
src/client/buffer_stream.cpp (+9/-9) src/client/mir_connection.cpp (+12/-12) src/client/mir_prompt_session.cpp (+7/-7) src/client/mir_screencast.cpp (+5/-5) src/client/mir_surface.cpp (+13/-13) src/client/rpc/mir_protobuf_rpc_channel.cpp (+3/-3) src/include/common/mir/make_protobuf_object.h (+2/-5) src/protobuf/mir_protobuf.proto (+24/-23) src/server/frontend/event_sender.cpp (+23/-22) src/server/frontend/protobuf_message_processor.cpp (+11/-10) src/server/frontend/protobuf_responder.cpp (+10/-6) src/server/frontend/protobuf_responder.h (+1/-1) src/server/frontend/socket_connection.cpp (+7/-6) |
To merge this branch: | bzr merge lp://qastaging/~albaguirre/mir/server-improve-abi-compat-with-mirprotobuf |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Robert Carr (community) | Approve | ||
Alexandros Frantzis (community) | Approve | ||
Chris Halse Rogers | Approve | ||
Daniel van Vugt | Abstain | ||
PS Jenkins bot (community) | continuous-integration | Approve | |
Review via email:
|
Commit message
Improve ABI compatibility between mirserver and mirprotobuf.
server: Avoid allocating protobuf objects on the stack to avoid mismatched message definitions between server and future revision of the mirprotobuf library.
protobuf: Avoid class layout changes in protobuf generated code. The protobuf compiler uses order of appearance when generating classes and array offsets from a *.proto file. New fields should always go at the end of a message definition. New message definitions also need to be declared at the end of the file to avoid changes to some generated array index offsets.
Description of the change
Improve ABI compatibility between mirserver and mirprotobuf.
server: Avoid allocating protobuf objects on the stack to avoid mismatched message definitions between server and future revision of the mirprotobuf library.
protobuf: Avoid class layout changes in protobuf generated code. The protobuf compiler uses order of appearance when generating classes and array offsets from a *.proto file. New fields should always go at the end of a message definition. New message definitions also need to be declared at the end of the file to avoid changes to some generated array index offsets.
Unmerged revisions
- 2766. By Alberto Aguirre
-
server:: Allocate mir::protobuf objects on the heap through their factory methods.
Avoid allocating protobuf objects on the stack to avoid mismatched message definitions between
server and mirprotobuf library. This improves ABI compatiblity with future revisions of mirprotobuf. - 2765. By Alberto Aguirre
-
Avoid class layout changes in protobuf generated code to keep ABI compatibility in libmirprotobuf
The protobuf compiler uses order of apperance (not sequence numbers) when generating classes and table offsets.
New message definitions also need to be delcared at the end of the file to avoid changes to some generated array index offsets. - 2764. By Alberto Aguirre
-
Move make_protobuf_
object as it will be needed on server side as well
PASSED: Continuous integration, rev:2766 jenkins. qa.ubuntu. com/job/ mir-ci/ 4387/ jenkins. qa.ubuntu. com/job/ mir-android- vivid-i386- build/3254 s-jenkins. ubuntu- ci:8080/ job/mir- clang-ts- wily-amd64- build/107 jenkins. qa.ubuntu. com/job/ mir-clang- wily-amd64- build/779 jenkins. qa.ubuntu. com/job/ mir-mediumtests -vivid- touch/3202 jenkins. qa.ubuntu. com/job/ mir-wily- amd64-ci/ 536 jenkins. qa.ubuntu. com/job/ mir-wily- amd64-ci/ 536/artifact/ work/output/ *zip*/output. zip jenkins. qa.ubuntu. com/job/ mir-mediumtests -builder- vivid-armhf/ 3202 jenkins. qa.ubuntu. com/job/ mir-mediumtests -builder- vivid-armhf/ 3202/artifact/ work/output/ *zip*/output. zip jenkins. qa.ubuntu. com/job/ mir-mediumtests -runner- mako/6002 s-jenkins. ubuntu- ci:8080/ job/touch- flash-device/ 22038
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild: s-jenkins. ubuntu- ci:8080/ job/mir- ci/4387/ rebuild
http://