added possibility to dynamically register RPCs