mostly done refactor, fixed writer and subscriber today