Subject: Lifecycle events and mir_connection_release

From: Christopher James Halse Rogers <[email-masked]>
Date: Fri, 18 Jul 2014 14:40:09 +1000

Hey, y'all.

One of the things the RPC transport rework has shaken out is the 
interaction of mir_lifecycle_connection_lost and mir_connection_release.

Previously, mir_connection_release would not generate a connection_lost 
lifecycle event; now it (mostly) does, and this is reflected in the 
updates to the tests.

Really it should be deterministically one way or the other, though.

What is the behaviour we desire here? Should mir_connection_release 
guarantee that mir_lifecycle_connection_lost is never generated in 
response, or that mir_lifecycle_connection_lost is always generated in 
response.

I favour the latter; it means that clients can always assume that 
they'll receive a connection_lost message and can trigger cleanup 
accordingly. Otherwise they need to cleanup triggered by 
connection_lost or by some part of the code calling connection_release.