On Tue 2014-02-11 12:26, Gunnar Morling wrote:
> 2014/2/11 Davide D'Alto <daltodav...@gmail.com>
> 
> > > Yes, that helps indeed. Implementing my validation routine in such an
> > observer works. I guess if needed, I even could implement support for the
> > suggested service contract in OGM with help of an observer.
> >
> > In OGM, we used to have a SessionFactoryObserver but we removed it in
> > favor of the SessionFactoryServiceInitiator.
> > https://hibernate.atlassian.net/browse/OGM-299
> >
> >
> But do we have a DatastoreProvider which actually makes use of the SF?
> 
> I can "inject" the SF into a DatastoreProvider by having it implement said
> StartStoppable contract. But as pointed out before the SF is not yet
> completely initialized at this point. So I e.g. can't access the entity
> persisters.
> 
> I couldn't find any "real" implementation of StartStoppable (besides a
> testing one); it might actually make sense to re-implement the support for
> this contract using an observer, which would expose a fully-initialized SF
> to such implementations.

My reason for StartStoppable receiving the metadata was to offer the
datstore provider the ability to generate or verify the database schema
creation. The Cassandra prototypes did use that.
_______________________________________________
hibernate-dev mailing list
hibernate-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hibernate-dev

Reply via email to