Example #1
0
 private Map<String, Set<String>> getDefaultOAuth2ProviderAttributes(SSOToken token)
     throws WorkflowException {
   try {
     final ServiceSchema serviceSchema =
         new ServiceSchemaManager(SERVICE_NAME, token).getOrganizationSchema();
     return SMSUtils.removeValidators(serviceSchema.getReadOnlyAttributeDefaults(), serviceSchema);
   } catch (SMSException e) {
     DEBUG.error(
         "An error occurred while trying to read the default OAuth2 Provider settings.", e);
     throw new WorkflowException("oauth2.provider.read.error", null);
   } catch (SSOException e) {
     DEBUG.error(
         "An error occurred while trying to read the default OAuth2 Provider settings.", e);
     throw new WorkflowException("oauth2.provider.read.error", null);
   }
 }