Class AclClassIdInitializer
java.lang.Object
ubic.gemma.persistence.util.AclClassIdInitializer
- All Implemented Interfaces:
org.springframework.beans.factory.InitializingBean
@Component
public class AclClassIdInitializer
extends Object
implements org.springframework.beans.factory.InitializingBean
Stash the
SessionFactoryImplementor onto AclQueryUtils.sessionFactory
at Spring init. AclQueryUtils is a static utility that needs an open session
to resolve acl_class.id from a Securable class name (see
resolveAclClassId). A Hibernate-internal Query.unwrap doesn't
give us a workable session reference, so we cache the factory once at startup
and open a fresh StatelessSession for the lookup.
jakarta.annotation.PostConstruct isn't on the gemma-core classpath
(the @PostConstruct dep was dropped in the Phase 3 Jakarta cleanup);
Spring's InitializingBean provides the same lifecycle slot.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
AclClassIdInitializer
-
-
Method Details
-
afterPropertiesSet
public void afterPropertiesSet()- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean
-