add push/pull routines, further cleanup