Ejemplo n.º 1
0
  public double getNotificationFee() throws EtccException {

    CacheAdmin admin = CacheAdmin.getInstance();
    String key = AppEnum.NOTIFICATION_FEE.getValue();
    Double result = (Double) admin.getFromCache(key);
    try {

      if (result == null) {
        result = app.getNotificationFee();
        admin.putInCache(key, result);
      }
      return result;
    } catch (Throwable t) {
      admin.cancelUpdate(key);
      logger.error(t);
      throw new EtccException("Error running getNotificationFee: " + t, t);
    }
  }