Updates to factory, to allow for s/resource/entity/ changes