pushData and some minor architectural changes from master.