[java-identity-provider COMMIT] in /trunk: idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relying...

noreply at shibboleth.net noreply at shibboleth.net
Mon Nov 10 12:22:27 EST 2014


Author: rdw
Date: Mon Nov 10 12:22:27 2014
New Revision: 6869

URL: http://svn.shibboleth.net/view/java-identity-provider?rev=6869&view=rev
Log:
IDP-507 Add sortKey into top level MetadataProviders, and test/

Added:
    trunk/idp-profile-spring/src/test/resources/net/shibboleth/idp/profile/spring/relyingparty/metadata/inLineChain.xml
      - copied, changed from r6865, trunk/idp-profile-spring/src/test/resources/net/shibboleth/idp/profile/spring/relyingparty/metadata/inLineEntity2.xml
    trunk/idp-profile-spring/src/test/resources/net/shibboleth/idp/profile/spring/relyingparty/metadata/inLineEntities2.xml   (with props)
Modified:
    trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/RelyingPartyGroupParser.java
    trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/AbstractMetadataProviderParser.java
    trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/MetadataResolverServiceStrategy.java
    trunk/idp-profile-spring/src/test/java/net/shibboleth/idp/profile/spring/relyingparty/MultiSourceFileTest.java
    trunk/idp-profile-spring/src/test/resources/net/shibboleth/idp/profile/spring/relyingparty/metadata/inLineEntity.xml
    trunk/idp-profile-spring/src/test/resources/net/shibboleth/idp/profile/spring/relyingparty/metadata/inLineEntity2.xml
    trunk/idp-profile-spring/src/test/resources/net/shibboleth/idp/profile/spring/relyingparty/metadata/serviceBeans.xml
    trunk/idp-saml-impl/src/main/java/net/shibboleth/idp/saml/metadata/impl/RelyingPartyMetadataProvider.java
    trunk/idp-schema/src/main/resources/schema/shibboleth-metadata.xsd

Modified: trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/RelyingPartyGroupParser.java
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/RelyingPartyGroupParser.java?rev=6869&r1=6868&r2=6869&view=diff
==============================================================================
--- trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/RelyingPartyGroupParser.java (original)
+++ trunk/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/RelyingPartyGroupParser.java Mon Nov 10 12:22:27 2014
@@ -27,7 +27,6 @@
 import net.shibboleth.idp.profile.spring.relyingparty.metadata.MetadataNamespaceHandler;
 import net.shibboleth.idp.profile.spring.relyingparty.security.SecurityNamespaceHandler;
 import net.shibboleth.idp.relyingparty.impl.DefaultRelyingPartyConfigurationResolver;
-import net.shibboleth.idp.saml.metadata.impl.RelyingPartyMetadataProvider;
 import net.shibboleth.utilities.java.support.xml.ElementSupport;
 
 import org.opensaml.security.x509.tls.impl.BasicClientTLSValidationConfiguration;
@@ -44,7 +43,9 @@
  * Parser for <RelyingPartyGroup>
  * 
  * <p>This parser summons up two beans: a {@link DefaultRelyingPartyConfigurationResolver} which deals with the
- * RelyingParty bit of the file, and a series of {@link RelyingPartyMetadataProvider}s which deal with the metadata
+ * RelyingParty bit of the file, and a series of 
+ * {@link RelyingPartyGroupParser.ELEMENT_NAME.getNamespaceURI().equals(parent.getNamespaceURI());}s which 
+ * deal with the metadata
  * configuration.</p>
  */
 public class RelyingPartyGroupParser extends AbstractSingleBeanDefinitionParser {
@@ -91,27 +92,8 @@
         builder.addPropertyValue("unverifiedConfiguration", anonRps.get(0));
         
         // Metadata
-
-        final List<BeanDefinition> metadataProviders =
-                SpringSupport.parseCustomElements(configChildren.get(MetadataNamespaceHandler.METADATA_ELEMENT_NAME),
-                        parserContext);
-
-        if (metadataProviders != null && metadataProviders.size() > 0) {
-            for (BeanDefinition metadataProvider : metadataProviders) {
-                final BeanDefinitionBuilder metadataBuilder =
-                        BeanDefinitionBuilder.genericBeanDefinition(RelyingPartyMetadataProvider.class);
-                metadataBuilder.setLazyInit(true);
-                metadataBuilder.setInitMethodName("initialize");
-                metadataBuilder.setDestroyMethodName("destroy");
-
-                metadataBuilder.setInitMethodName("initialize");
-                metadataBuilder.setDestroyMethodName("destroy");
-                metadataBuilder.addConstructorArgValue(metadataProvider);
-                BeanDefinition rpDefinition = metadataBuilder.getBeanDefinition();
-                parserContext.getRegistry().registerBeanDefinition(
-                        parserContext.getReaderContext().generateBeanName(rpDefinition), rpDefinition);
-            }
-        }
+        SpringSupport.parseCustomElements(configChildren.get(MetadataNamespaceHandler.METADATA_ELEMENT_NAME),
+                parserContext);
 
         // <Credential> (for metadata & signing)

[... 408 lines stripped ...]


More information about the commits mailing list