Class ManagedConnectionParser
java.lang.Object
net.shibboleth.idp.attribute.resolver.spring.dc.impl.ManagedConnectionParser
Utility class for parsing v2 managed connection configuration.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionManagedConnectionParser
(Element config) Creates a new ManagedConnectionParser with the supplied element. -
Method Summary
Modifier and TypeMethodDescriptionstatic DataSource
buildDataSource
(String resourceName) Factory builder a container managed datasource.protected BeanDefinition
createContainerManagedDataSource
(Element containerManagedElement) Creates a container managed data source bean definition.Creates a data source bean definition from a v2 XML configuration.protected BeanDefinition
createSimpleManagedDataSource
(Element simpleManagedElement) Creates an simple managed data source bean definition based on dbcp2.static String
getBeanDataSourceID
(Element config) Get the bean ID of an externally defined data source.
-
Field Details
-
CONTAINER_MANAGED_CONNECTION_RESOLVER
resolver:ContainerManagedConnection. -
BEAN_MANAGED_CONNECTION_RESOLVER
resolver:BeanManagedConnection. -
SIMPLE_MANAGED_CONNECTION_RESOLVER
resolver:SimpleManagedConnection. -
LOG
@Nonnull private static final org.slf4j.Logger LOGLogger. -
configElement
Data source XML element.
-
-
Constructor Details
-
ManagedConnectionParser
Creates a new ManagedConnectionParser with the supplied element.- Parameters:
config
- element
-
-
Method Details
-
createDataSource
Creates a data source bean definition from a v2 XML configuration.- Returns:
- data source bean definition
-
createContainerManagedDataSource
@Nonnull protected BeanDefinition createContainerManagedDataSource(@Nonnull Element containerManagedElement) Creates a container managed data source bean definition.- Parameters:
containerManagedElement
- to parse- Returns:
- data source bean definition
-
createSimpleManagedDataSource
@Nonnull protected BeanDefinition createSimpleManagedDataSource(@Nonnull Element simpleManagedElement) Creates an simple managed data source bean definition based on dbcp2.- Parameters:
simpleManagedElement
- to parse- Returns:
- data source bean definition
-
buildDataSource
Factory builder a container managed datasource.- Parameters:
resourceName
- of the data source- Returns:
- data source or null if the data source cannot be looked up
-
getBeanDataSourceID
Get the bean ID of an externally defined data source.- Parameters:
config
- the config element- Returns:
- data source bean ID
-