Skip to content

Commit

Permalink
Merge pull request #1012 from zyro23/grails-core-10824
Browse files Browse the repository at this point in the history
grails/grails-core#10824 - HibernateDatastoreConnectionSourcesRegistrar implements Ordered
  • Loading branch information
graemerocher committed Oct 19, 2017
2 parents 6c66fc5 + 43f6dd6 commit 3482bd6
Showing 1 changed file with 7 additions and 1 deletion.
Expand Up @@ -12,6 +12,7 @@ import org.springframework.beans.factory.config.ConstructorArgumentValues
import org.springframework.beans.factory.support.BeanDefinitionRegistry
import org.springframework.beans.factory.support.BeanDefinitionRegistryPostProcessor
import org.springframework.beans.factory.support.RootBeanDefinition
import org.springframework.core.Ordered
import org.springframework.transaction.PlatformTransactionManager

import javax.sql.DataSource
Expand All @@ -24,7 +25,7 @@ import javax.sql.DataSource
* @since 6.0.6
*/
@CompileStatic
class HibernateDatastoreConnectionSourcesRegistrar implements BeanDefinitionRegistryPostProcessor {
class HibernateDatastoreConnectionSourcesRegistrar implements BeanDefinitionRegistryPostProcessor, Ordered {

final Iterable<String> dataSourceNames

Expand Down Expand Up @@ -90,4 +91,9 @@ class HibernateDatastoreConnectionSourcesRegistrar implements BeanDefinitionRegi
void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) throws BeansException {
// no-op
}

@Override
int getOrder() {
return Ordered.HIGHEST_PRECEDENCE + 100
}
}

0 comments on commit 3482bd6

Please sign in to comment.