public synchronized void storeManagedData(Object managedData){
  Map<String,Object> toStore=buildMapToStore(managedData);
  String resourceId=getResourceId();
  try {
    storage.store(resourceId,toStore);
    lastUpdateSinceInitialization=new Date();
  }
 catch (  Throwable storeErr) {
    if (initializedOn != null) {
      try {
        reloadFromStorage();
      }
 catch (      Exception reloadExc) {
        log.error("Failed to load data from storage due to: " + reloadExc);
      }
    }
    String errMsg=String.format(Locale.ROOT,"Failed to store data for %s due to: %s",resourceId,storeErr.toString());
    log.error(errMsg,storeErr);
    throw new ResourceException(Status.SERVER_ERROR_INTERNAL,errMsg,storeErr);
  }
}

public synchronized void storeManagedData ( Object managedData ) { Map < String , Object > toStore = buildMapToStore ( managedData ) ; String resourceId = getResourceId ( ) ; try { storage . store ( resourceId , toStore ) ; lastUpdateSinceInitialization = new Date ( ) ; } catch ( Throwable storeErr ) { if ( initializedOn != null ) { try { reloadFromStorage ( ) ; } catch ( Exception reloadExc ) { log . error ( "Failed to load data from storage due to: " + reloadExc ) ; } } String errMsg = String . format ( Locale . ROOT , "Failed to store data for %s due to: %s" , resourceId , storeErr . toString ( ) ) ; log . error ( errMsg , storeErr ) ; throw new ResourceException ( Status . SERVER_ERROR_INTERNAL , errMsg , storeErr ) ; } }
persists managed data to the configured storage io as a json object .
