code: @Override
      public void onApplicationEvent(final ResourceChangeDetectingEventNotifier.ResourceChangedEvent resourceChangedEvent) {
          try {
              if (!resourceChangedEvent.getResourceUri().equals(this.personAttributesConfigFile.getURI())) {
                  //Not our resource. Just get out of here.
                  return;
              }
          }
          catch (final Throwable e) {
              logger.error("An exception is caught while trying to access JSON resource: ", e);
              return;
          }
  
          final Map<String, Map<String, List<Object>>> savedBackingMap;
          synchronized (this.synchronizationMonitor) {
              //Save the current state here in order to restore it, should the error occur.
              savedBackingMap = super.getBackingMap();
          }
          try {
              unmarshalAndSetBackingMap();
          }
          catch (final Throwable ex) {
              logger.error("An exception is caught during reloading of the JSON configuration:", ex);
              //Restore the old state. If the error occurs at this stage, well nothing we could do here. Just propagate the exception.
              synchronized (this.synchronizationMonitor) {
                  super.setBackingMap(savedBackingMap);
              }
          }
      }
docs: Reload person attributes when JSON config is changed. In case of un-marshaling errors,
  or any other errors, do not disturb running CAS server by propagating the exceptions,
  but instead log the error and leave the previously cached person attributes state alone.
  
  @param resourceChangedEvent event representing the resource change. Might not actually correspond
  to this JSON config file, so the URI of it needs to be checked first.