How to make rm-sessions upgradeable?

Taru Karttunen taruti at ...102...
Sat Sep 15 10:56:44 CEST 2012


Hello

When spawning more threads the rm-session from the env needs to be
upgraded in various places. This can occur when spawning new threads and
even in thread.start().

Thus one needs a way to make the rm-session in env upgradeable from the
outside.

A simple way to fix would be to define a
class Upgradeable_rm_session : public Rm_session {
      void upgrade(const char *);
};

And make some private inheritance into protected inheritance 
i.e. Rpc_client into
template <typename RPC_INTERFACE>
struct Rpc_client : *protected* Capability<RPC_INTERFACE>, RPC_INTERFACE
...

Is there a better and more non-invasive way to do this?

If not - would a patch implementing this be accepted?

An alternative would be to expose the capability in env in addition to
the session, but I think that is even more ugly.

- Taru Karttunen





More information about the users mailing list