Class DataAutoConfiguration
- java.lang.Object
-
- com.netflix.genie.web.spring.autoconfigure.data.DataAutoConfiguration
-
@Configuration @EnableJpaRepositories("com.netflix.genie.web.data.services.impl.jpa.repositories") @EntityScan("com.netflix.genie.web.data.services.impl.jpa.entities") public class DataAutoConfiguration extends java.lang.Object
Default auto configuration of data related services and beans for Genie.- Since:
- 4.0.0
-
-
Constructor Summary
Constructors Constructor Description DataAutoConfiguration()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataServices
genieDataServices(PersistenceService persistenceService)
Provide aDataServices
instance if one isn't already in the context.JpaRepositories
genieJpaRepositories(JpaApplicationRepository applicationRepository, JpaClusterRepository clusterRepository, JpaCommandRepository commandRepository, JpaCriterionRepository criterionRepository, JpaFileRepository fileRepository, JpaJobRepository jobRepository, JpaTagRepository tagRepository)
Provide aJpaRepositories
container instance if one wasn't already provided.JpaPersistenceServiceImpl
geniePersistenceService(javax.persistence.EntityManager entityManager, JpaRepositories jpaRepositories, BraveTracingComponents tracingComponents)
Provide a default implementation ofPersistenceService
if no other has been defined.
-
-
-
Method Detail
-
genieDataServices
@Bean @ConditionalOnMissingBean(DataServices.class) public DataServices genieDataServices(PersistenceService persistenceService)
Provide aDataServices
instance if one isn't already in the context.- Parameters:
persistenceService
- ThePersistenceService
implementation to use- Returns:
- A
DataServices
instance
-
genieJpaRepositories
@Bean @ConditionalOnMissingBean(JpaRepositories.class) public JpaRepositories genieJpaRepositories(JpaApplicationRepository applicationRepository, JpaClusterRepository clusterRepository, JpaCommandRepository commandRepository, JpaCriterionRepository criterionRepository, JpaFileRepository fileRepository, JpaJobRepository jobRepository, JpaTagRepository tagRepository)
Provide aJpaRepositories
container instance if one wasn't already provided.- Parameters:
applicationRepository
- TheJpaApplicationRepository
instanceclusterRepository
- TheJpaClusterRepository
instancecommandRepository
- TheJpaCommandRepository
instancecriterionRepository
- TheJpaCriterionRepository
instancefileRepository
- TheJpaFileRepository
instancejobRepository
- TheJpaJobRepository
instancetagRepository
- TheJpaTagRepository
instance- Returns:
- A new
JpaRepositories
instance to simplify passing around all repositories
-
geniePersistenceService
@Bean @ConditionalOnMissingBean(PersistenceService.class) public JpaPersistenceServiceImpl geniePersistenceService(javax.persistence.EntityManager entityManager, JpaRepositories jpaRepositories, BraveTracingComponents tracingComponents)
Provide a default implementation ofPersistenceService
if no other has been defined.- Parameters:
entityManager
- TheEntityManager
for this applicationjpaRepositories
- TheJpaRepositories
for GenietracingComponents
- TheBraveTracingComponents
instance to use- Returns:
- A
JpaPersistenceServiceImpl
instance which implementsPersistenceService
backed by JPA and a relational database
-
-