Key<NoSqlRawSession> key = Key.get(NoSqlRawSession.class, named);
NoSqlRawSession inst = injector.getInstance(key);
inst.start(properties);
//why not just add setInjector() and setup() in NoSqlEntityManagerFactory
BaseEntityManagerFactoryImpl impl = (BaseEntityManagerFactoryImpl)factory;
impl.setInjector(injector);
ClassLoader cl = cl2;
if(cl == null)
cl = BootstrapImpl.class.getClassLoader();
//The expensive scan all entities occurs here...
impl.setup(properties, converters, cl);
return impl;
}