More scaffolding, batch changes

These big changes should settle down soon.

A bug has been opened at Bugzilla for this at
https://bugzilla.mozilla.org/show_bug.cgi?id=877311