removed autopublish and setup pub/sub