if (ofFactoryRegistry == null) {
ofFactoryRegistry = new LifecycleManagersRegistry();
ofFactoryRegistry.addFactoryFactory(new ScopeLifecycleManager<Object>());
ofFactoryRegistry.addFactoryFactory(new JSR250LifecycleManager<Object>());
}
ApplicationValidator applicationValidator = new ApplicationValidator();
providersRegistry = new ProvidersRegistry(ofFactoryRegistry, applicationValidator);
resourceRegistry =
new ResourceRegistry(ofFactoryRegistry, applicationValidator, properties);
}