Examples of GoraException


Examples of org.apache.gora.util.GoraException

      return dataStore;

    } catch (GoraException ex) {
      throw ex;
    } catch(Exception ex) {
      throw new GoraException(ex);
    }
  }
View Full Code Here

Examples of org.apache.gora.util.GoraException

        = (Class<? extends DataStore<K, T>>) Class.forName(dataStoreClass);
      return createDataStore(c, keyClass, persistentClass, conf, createProps(), null);
    } catch(GoraException ex) {
      throw ex;
    } catch (Exception ex) {
      throw new GoraException(ex);
    }
  }
View Full Code Here

Examples of org.apache.gora.util.GoraException

      Class<T> p = (Class<T>) ClassLoadingUtils.loadClass(persistentClass);
      return createDataStore(c, k, p, conf, createProps(), null);
    } catch(GoraException ex) {
      throw ex;
    } catch (Exception ex) {
      throw new GoraException(ex);
    }
  }
View Full Code Here

Examples of org.apache.gora.util.GoraException

    Properties createProps = createProps();
    Class<? extends DataStore<K, T>> c;
    try {
      c = (Class<? extends DataStore<K, T>>) Class.forName(getDefaultDataStore(createProps));
    } catch (Exception ex) {
      throw new GoraException(ex);
    }
    return createDataStore(c, keyClass, persistent, conf, createProps, null);
  }
View Full Code Here

Examples of org.apache.gora.util.GoraException

        object = mapper.load(persistentClass, hashKey, rangeKey);
      else
        object = mapper.load(persistentClass, hashKey);
      }
      else
        throw new GoraException("Error while retrieving keys from object: " + key.toString());
    } catch (IllegalArgumentException e) {
      e.printStackTrace();
    } catch (IllegalAccessException e) {
      e.printStackTrace();
    } catch (InvocationTargetException e) {
View Full Code Here

Examples of org.apache.gora.util.GoraException

        else
          mapper.load(persistentClass, hashKey.toString());
          mapper.save(obj);
      }
      else
        throw new GoraException("Error while retrieving keys from object: " + obj.toString());
    }catch(NullPointerException npe){
      LOG.error("Error while putting an item. " + npe.toString());
      npe.printStackTrace();
    }catch(Exception e){
      LOG.error("Error while putting an item. " + obj.toString());
View Full Code Here

Examples of org.apache.gora.util.GoraException

        } else {
          data = decoder.readBytes(null).array();
        }
      } catch (IOException e) {
        e.printStackTrace();
        throw new GoraException("Error decoding union type: ", e);
      }
    } else {
      fromSchema = schema;
    }
    return fromBytes(encoder, fromSchema, data);
View Full Code Here

Examples of org.apache.gora.util.GoraException

        }

      }

      if (mapping.tableName == null) {
        throw new GoraException("Please define the accumulo 'table' name mapping in " + filename + " for " + persistentClass.getCanonicalName());
      }

      nl = root.getElementsByTagName("table");
      for (int i = 0; i < nl.getLength(); i++) {
        Element tableElement = (Element) nl.item(i);
View Full Code Here

Examples of org.apache.gora.util.GoraException

        Object o = val.get(field.pos());      

        Pair<Text,Text> col = mapping.fieldMap.get(field.name());

        if (col == null) {
          throw new GoraException("Please define the gora to accumulo mapping for field " + field.name());
        }

        switch (field.schema().getType()) {
        case MAP:
          count = putMap(m, count, field.schema().getValueType(), o, col);
View Full Code Here

Examples of org.apache.gora.util.GoraException

      return dataStore;

    } catch (GoraException ex) {
      throw ex;
    } catch(Exception ex) {
      throw new GoraException(ex);
    }
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.