refactor resource bootstrapping into dedicated service that can be reused by extensions