Skip to content

Commit

Permalink
Merge branch 'feature/shibui-2269' of bitbucket.org:unicon/shib-idp-u…
Browse files Browse the repository at this point in the history
…i into feature/SHIBUI-2269-external-filters
  • Loading branch information
rmathis committed Jun 28, 2022
2 parents ba34b5e + 57c5fe2 commit 48b2e42
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

import static edu.internet2.tier.shibboleth.admin.ui.jsonschema.JsonSchemaResourceLocation.*;
import static edu.internet2.tier.shibboleth.admin.ui.jsonschema.JsonSchemaResourceLocation.SchemaType.ENTITY_ATTRIBUTES_FILTERS;
import static edu.internet2.tier.shibboleth.admin.ui.jsonschema.JsonSchemaResourceLocation.SchemaType.EXTERNAL_METADATA_RESOLVER;
import static edu.internet2.tier.shibboleth.admin.ui.jsonschema.JsonSchemaResourceLocation.SchemaType.METADATA_SOURCES;
import static edu.internet2.tier.shibboleth.admin.ui.jsonschema.JsonSchemaResourceLocation.SchemaType.FILESYSTEM_METADATA_RESOLVER;
import static edu.internet2.tier.shibboleth.admin.ui.jsonschema.JsonSchemaResourceLocation.SchemaType.LOCAL_DYNAMIC_METADATA_RESOLVER;
Expand Down Expand Up @@ -57,6 +58,8 @@ public class JsonSchemaComponentsConfiguration {
@Setter
private String nameIdFormatFilterUiSchemaLocation = "classpath:nameid-filter.schema.json";

private String externalMetadataResolverUiSchemaLocation = "classpath:external.schema.json";

@Bean
public JsonSchemaResourceLocationRegistry jsonSchemaResourceLocationRegistry(ResourceLoader resourceLoader, ObjectMapper jacksonMapper) {
return JsonSchemaResourceLocationRegistry.inMemory()
Expand Down Expand Up @@ -90,6 +93,12 @@ public JsonSchemaResourceLocationRegistry jsonSchemaResourceLocationRegistry(Res
.jacksonMapper(jacksonMapper)
.detectMalformedJson(true)
.build())
.register(EXTERNAL_METADATA_RESOLVER, JsonSchemaLocationBuilder.with()
.jsonSchemaLocation(externalMetadataResolverUiSchemaLocation)
.resourceLoader(resourceLoader)
.jacksonMapper(jacksonMapper)
.detectMalformedJson(true)
.build())
.register(NAME_ID_FORMAT_FILTER, JsonSchemaLocationBuilder.with()
.jsonSchemaLocation(nameIdFormatFilterUiSchemaLocation)
.resourceLoader(resourceLoader)
Expand Down

0 comments on commit 48b2e42

Please sign in to comment.