public class ClusterAwareBeanSelector extends Object implements org.springframework.beans.factory.BeanFactoryAware
Constructor and Description |
---|
ClusterAwareBeanSelector(ClusterManager clusterManager) |
Modifier and Type | Method and Description |
---|---|
<T> T |
selectBean(Class<T> beanType,
String beanNameForCluster,
String beanNameForNonCluster)
Selects one of 2 beans
|
void |
setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) |
public ClusterAwareBeanSelector(ClusterManager clusterManager)
public <T> T selectBean(Class<T> beanType, String beanNameForCluster, String beanNameForNonCluster)
beanType
- The common base type of both beansbeanNameForCluster
- The name of the bean that should be selected if Confluence is in clustered mode.beanNameForNonCluster
- The name of the bean that should be selected if Onfluence is NOT in clustered mode.public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) throws org.springframework.beans.BeansException
setBeanFactory
in interface org.springframework.beans.factory.BeanFactoryAware
org.springframework.beans.BeansException
Copyright © 2003–2021 Atlassian. All rights reserved.