org.openspaces.core.cluster
Class ClusterInfoPropertyPlaceholderConfigurer
java.lang.Object
org.springframework.core.io.support.PropertiesLoaderSupport
org.springframework.beans.factory.config.PropertyResourceConfigurer
org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
org.openspaces.core.cluster.ClusterInfoPropertyPlaceholderConfigurer
- All Implemented Interfaces:
- ClusterInfoAware, BeanFactoryAware, BeanNameAware, BeanFactoryPostProcessor, Ordered, PriorityOrdered
public class ClusterInfoPropertyPlaceholderConfigurer
- extends PropertyPlaceholderConfigurer
- implements BeanNameAware, BeanFactoryAware, ClusterInfoAware
Provides the ClusterInfo
parameters as injected
properties that can be used within Spring application context. The following is a list of the
properties:
If the cluster info parameter is not set (has null
value) an empty string will be used.
- Author:
- kimchy
Methods inherited from class org.springframework.beans.factory.config.PropertyPlaceholderConfigurer |
parseStringValue, resolvePlaceholder, resolvePlaceholder, resolveSystemProperty, setIgnoreUnresolvablePlaceholders, setNullValue, setPlaceholderPrefix, setPlaceholderSuffix, setSearchSystemEnvironment, setSystemPropertiesMode, setSystemPropertiesModeName |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NUMBER_OF_INSTANCES_PROP
public static final String NUMBER_OF_INSTANCES_PROP
- See Also:
- Constant Field Values
NUMBER_OF_BACKUPS_PROP
public static final String NUMBER_OF_BACKUPS_PROP
- See Also:
- Constant Field Values
INSTANCE_ID_PROP
public static final String INSTANCE_ID_PROP
- See Also:
- Constant Field Values
BACKUP_ID_PROP
public static final String BACKUP_ID_PROP
- See Also:
- Constant Field Values
SCHEMA_PROP
public static final String SCHEMA_PROP
- See Also:
- Constant Field Values
RUNNING_NUMBER_PROP
public static final String RUNNING_NUMBER_PROP
- See Also:
- Constant Field Values
RUNNING_NUMBER_OFFEST_1_PROP
public static final String RUNNING_NUMBER_OFFEST_1_PROP
- See Also:
- Constant Field Values
SUFFIX_PROP
public static final String SUFFIX_PROP
- See Also:
- Constant Field Values
NAME_PROP
public static final String NAME_PROP
- See Also:
- Constant Field Values
ClusterInfoPropertyPlaceholderConfigurer
public ClusterInfoPropertyPlaceholderConfigurer()
ClusterInfoPropertyPlaceholderConfigurer
public ClusterInfoPropertyPlaceholderConfigurer(ClusterInfo clusterInfo)
createProperties
public static Properties createProperties(ClusterInfo clusterInfo)
setClusterInfo
public void setClusterInfo(ClusterInfo clusterInfo)
- Description copied from interface:
ClusterInfoAware
- Sets the cluster information.
Note, the cluster information is obtained externally from the application context which means
that this feature need to be supported by specific containers (and is not supported by plain
Spring application context). This means that beans that implement ClusterInfoAware
should take into account the fact that the cluster info provided might be null.
- Specified by:
setClusterInfo
in interface ClusterInfoAware
- Parameters:
clusterInfo
- The cluster information to be injected
setBeanName
public void setBeanName(String beanName)
- Specified by:
setBeanName
in interface BeanNameAware
- Overrides:
setBeanName
in class PropertyPlaceholderConfigurer
setBeanFactory
public void setBeanFactory(BeanFactory beanFactory)
- Specified by:
setBeanFactory
in interface BeanFactoryAware
- Overrides:
setBeanFactory
in class PropertyPlaceholderConfigurer
processProperties
protected void processProperties(ConfigurableListableBeanFactory beanFactoryToProcess,
Properties props)
throws BeansException
- Overrides:
processProperties
in class PropertyPlaceholderConfigurer
- Throws:
BeansException
Copyright © GigaSpaces.