On Sat, Jan 5, 2019 at 3:42 PM kefu chai <tchaikov@xxxxxxxxx> wrote: > recently, when we are working on cross-core messenger[0], we found > that, in order to share the connection between cores we need to have > types like "seastar::lw_shared_ptr<seastar::foreign_ptr<ConnectionRef>>", > because > - the connections to peer OSDs are shared across cores, > - the connections are shared by multiple continuations on the local > core -- either locally or remotely. Well, I perceive this type as a clever solution to get back some of the properties seastar::foreign_ptr had taken from us. What worries me is that we need such heavy artillery at the very early stage of project life. > and we need to perform i/o on the core where the connection is > established. Many problems can be resolved by introducing another indirection layer. This becomes harder if a pointer that should be wrapped with foreign_ptr resides in a third-party component. Regards, Radek