extracted definition of updater callback from read loop