[java-identity-provider] branch maint-3.4 updated: IDP-1361 Deprecate <Resource> as a child of ResourceBackedMetadata Provider
Rod Widdowson
rdw at steadingsoftware.com
Sun Dec 9 11:19:54 EST 2018
This is an automated email from the git hooks/post-receive script.
rdw pushed a commit to branch maint-3.4
in repository java-identity-provider.
View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=83b0baf78442187d7a6777ee0e429e8cdc004284
The following commit(s) were added to refs/heads/maint-3.4 by this push:
new 83b0baf IDP-1361 Deprecate <Resource> as a child of ResourceBackedMetadata Provider
83b0baf is described below
commit 83b0baf78442187d7a6777ee0e429e8cdc004284
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Fri Dec 7 13:50:31 2018 +0000
IDP-1361 Deprecate <Resource> as a child of ResourceBackedMetadata Provider
https://issues.shibboleth.net/jira/browse/IDP-1361
---
.../metadata/impl/ResourceBackedMetadataProviderParser.java | 6 +++++-
.../spring/relyingparty/metadata/ResourceMetadataParserTest.java | 1 -
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/impl/ResourceBackedMetadataProviderParser.java b/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/impl/ResourceBackedMetadataProviderParser.java
index 4e1b52c..64504ab 100644
--- a/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/impl/ResourceBackedMetadataProviderParser.java
+++ b/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/impl/ResourceBackedMetadataProviderParser.java
@@ -82,9 +82,10 @@ public class ResourceBackedMetadataProviderParser extends AbstractReloadingMetad
if (AttributeSupport.hasAttribute(element, RESOURCE_REF)) {
return ResourceBackedMetadataResolver.class;
}
-
+
throw new BeanCreationException("No <Resource> specified for ResourceBackedMetadataProvider");
}
+
final QName qName = DOMTypeSupport.getXSIType(resources.get(0));
if (null == qName) {
log.error("No type specified for a <Resource> within a ResourceBackedMetadataProvider");
@@ -128,6 +129,9 @@ public class ResourceBackedMetadataProviderParser extends AbstractReloadingMetad
parserContext, builder);
return;
}
+ DeprecationSupport.warnOnce(ObjectType.ELEMENT, "Resource",
+ parserContext.getReaderContext().getResource().getDescription(),
+ "resourceRef property");
if (resources.size() != 1) {
log.error("{}: Only one Resource may be supplied to a ResourceBackedMetadataProvider", parserContext
diff --git a/idp-profile-spring/src/test/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/ResourceMetadataParserTest.java b/idp-profile-spring/src/test/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/ResourceMetadataParserTest.java
index f50692e..490ff2e 100644
--- a/idp-profile-spring/src/test/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/ResourceMetadataParserTest.java
+++ b/idp-profile-spring/src/test/java/net/shibboleth/idp/profile/spring/relyingparty/metadata/ResourceMetadataParserTest.java
@@ -28,7 +28,6 @@ import org.opensaml.saml.metadata.resolver.impl.HTTPMetadataResolver;
import org.opensaml.saml.metadata.resolver.impl.ResourceBackedMetadataResolver;
import org.opensaml.saml.saml2.metadata.EntityDescriptor;
import org.springframework.beans.factory.BeanCreationException;
-import org.springframework.core.io.ClassPathResource;
import org.springframework.mock.env.MockPropertySource;
import org.testng.Assert;
import org.testng.annotations.Test;
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list