Hello all,
I am using the MongoDB Service Registry. Reading from the registry works fine, also deletion of items is not a problem. However, when I try to create a new service or when I try to edit an existing service, I get the following error message.
[1;31m2017-07-21 10:33:02,368 ERROR
[org.apereo.cas.mgmt.services.web.AbstractManagementController] -
<JSON parse error: Can not deserialize instance of
org.apereo.cas.mgmt.services.web.beans.RegisteredServiceAttributeReleasePolicyStrategyEditBean
out of START_ARRAY token; nested exception is
com.fasterxml.jackson.databind.JsonMappingException: Can not deserialize
instance of
org.apereo.cas.mgmt.services.web.beans.RegisteredServiceAttributeReleasePolicyStrategyEditBean
out of START_ARRAY token
I am using the MongoDB that has been initialized with the following lines of code and contains exactly two items in collection
cas_service_registry.mongo "${CONNECTION_URL}" \
--eval \
'db.cas_service_registry.insertOne( { "_id" : NumberLong(10000002), "_class" : "org.apereo.cas.services.RegexRegisteredService", "serviceId" : "^https://www.apereo.org", "name" : "Apereo", "theme" : "apereo", "description" : "Apereo foundation sample service", "proxyPolicy" : { "_class" : "org.apereo.cas.services.RefuseRegisteredServiceProxyPolicy" }, "evaluationOrder" : 1, "usernameAttributeProvider" : { "_class" : "org.apereo.cas.services.DefaultRegisteredServiceUsernameProvider", "canonicalizationMode" : "NONE", "encryptUsername" : false }, "logoutType" : "BACK_CHANNEL", "requiredHandlers" : [ ], "attributeReleasePolicy" : { "_class" : "org.apereo.cas.services.ReturnAllowedAttributeReleasePolicy", "allowedAttributes" : [ ], "principalAttributesRepository" : { "_class" : "org.apereo.cas.authentication.principal.DefaultPrincipalAttributesRepository", "expiration" : NumberLong(2), "timeUnit" : "HOURS" }, "authorizedToReleaseCredentialPassword" : false, "authorizedToReleaseProxyGrantingTicket" : false, "excludeDefaultAttributes" : false }, "multifactorPolicy" : { "_class" : "org.apereo.cas.services.DefaultRegisteredServiceMultifactorPolicy", "multifactorAuthenticationProviders" : [ ], "failureMode" : "CLOSED", "bypassEnabled" : false }, "accessStrategy" : { "_class" : "org.apereo.cas.services.DefaultRegisteredServiceAccessStrategy", "enabled" : true, "ssoEnabled" : true, "requireAllAttributes" : true, "requiredAttributes" : { }, "rejectedAttributes" : { }, "caseInsensitive" : false }, "properties" : { } } )';
mongo "${CONNECTION_URL}" \
--eval \
'db.cas_service_registry.insertOne( { "_id" : NumberLong(10000001), "_class" : "org.apereo.cas.services.RegexRegisteredService", "serviceId" : "^(https|imaps)://.*", "name" : "HTTPS and IMAPS", "description" : "This service definition authorizes all application urls that support HTTPS and IMAPS protocols.", "proxyPolicy" : { "_class" : "org.apereo.cas.services.RefuseRegisteredServiceProxyPolicy" }, "evaluationOrder" : 10000, "usernameAttributeProvider" : { "_class" : "org.apereo.cas.services.DefaultRegisteredServiceUsernameProvider", "canonicalizationMode" : "NONE", "encryptUsername" : false }, "logoutType" : "BACK_CHANNEL", "requiredHandlers" : [ ], "attributeReleasePolicy" : { "_class" : "org.apereo.cas.services.ReturnAllowedAttributeReleasePolicy", "allowedAttributes" : [ ], "principalAttributesRepository" : { "_class" : "org.apereo.cas.authentication.principal.DefaultPrincipalAttributesRepository", "expiration" : NumberLong(2), "timeUnit" : "HOURS" }, "authorizedToReleaseCredentialPassword" : false, "authorizedToReleaseProxyGrantingTicket" : false, "excludeDefaultAttributes" : false }, "multifactorPolicy" : { "_class" : "org.apereo.cas.services.DefaultRegisteredServiceMultifactorPolicy", "multifactorAuthenticationProviders" : [ ], "failureMode" : "CLOSED", "bypassEnabled" : false }, "accessStrategy" : { "_class" : "org.apereo.cas.services.DefaultRegisteredServiceAccessStrategy", "enabled" : true, "ssoEnabled" : true, "requireAllAttributes" : true, "requiredAttributes" : { }, "rejectedAttributes" : { }, "caseInsensitive" : false }, "properties" : { } } )';