rewritten  PubSub interface