Package com.thinkaurelius.titan.diskstorage

Examples of com.thinkaurelius.titan.diskstorage.PermanentStorageException


                    log.debug("Cassandra cluster verified at size {} (schema version {}) in about {} ms",
                            new Object[]{curSize, version, System.currentTimeMillis() - start});
                    return;
                }
            } catch (Exception e) {
                throw new PermanentStorageException("Failed to fetch Cassandra Thrift schema versions: " +
                        ((e instanceof InvalidRequestException) ?
                                ((InvalidRequestException) e).getWhy() : e.getMessage()));
            }
        }
        throw new PermanentStorageException("Could not verify Cassandra cluster size");
    }
View Full Code Here


                log.debug("Keyspace {} and ColumnFamily {} were found.", ksName, cfName);
            }
        } catch (SchemaDisagreementException e) {
            throw new TemporaryStorageException(e);
        } catch (Exception e) {
            throw new PermanentStorageException(e);
        } finally {
            pool.returnObjectUnsafe(ksName, conn);
        }
    }
View Full Code Here

        try {
            client.system_add_column_family(createColumnFamily);
        } catch (SchemaDisagreementException e) {
            throw new TemporaryStorageException("Error in setting up column family", e);
        } catch (Exception e) {
            throw new PermanentStorageException(e);
        }

        log.debug("Added column family {} to keyspace {}.", cfName, ksName);
    }
View Full Code Here

            logger.debug("Substituted default CF name \"{}\" with short form \"{}\" to reduce HBase KeyValue size", longName, s);
        } else {
            if (shortCfNameMap.containsValue(longName)) {
                String fmt = "Must use CF long-form name \"%s\" instead of the short-form name \"%s\" when configured with %s=true";
                String msg = String.format(fmt, shortCfNameMap.inverse().get(longName), longName, SHORT_CF_NAMES_KEY);
                throw new PermanentStorageException(msg);
            }
            s = longName;
            logger.debug("Kept default CF name \"{}\" because it has no associated short form", s);
        }
        return s;
View Full Code Here

                }

                adm.enableTable(tableName);
            } catch (TableNotFoundException ee) {
                logger.error("TableNotFoundException", ee);
                throw new PermanentStorageException(ee);
            } catch (org.apache.hadoop.hbase.TableExistsException ee) {
                logger.debug("Swallowing exception {}", ee);
            } catch (IOException ee) {
                throw new TemporaryStorageException(ee);
            }
View Full Code Here

        assert sessionId == tx.getSessionId();

        try {
            tx.begin();
        } catch (PersistitException ex) {
            throw new PermanentStorageException(ex);
        }
    }
View Full Code Here

                        }
                    }
                    close();
                }
            } catch (PersistitException ex) {
                throw new PermanentStorageException(ex);
            }
        }
    }
View Full Code Here

        if (null == rows || 0 == rows.size())
            return null;

        if (1 < rows.size())
            throw new PermanentStorageException("Received " + rows.size()
                    + " rows from a single-key-column cassandra read");

        assert 1 == rows.size();

        Row r = rows.get(0);
View Full Code Here

            try {
                assign();
                exchange = db.getExchange(VOLUME_NAME, treeName, create);
                return exchange;
            } catch (PersistitException ex) {
                throw new PermanentStorageException(ex);
            }
        }
    }
View Full Code Here

    public KeyIterator getKeys(KeyRangeQuery keyRangeQuery, StoreTransaction txh) throws StorageException {
        IPartitioner partitioner = StorageService.getPartitioner();

        // see rant about this in Astyanax implementation
        if (partitioner instanceof RandomPartitioner || partitioner instanceof Murmur3Partitioner)
            throw new PermanentStorageException("This operation is only supported when byte-ordered partitioner is used.");

        return new RowIterator(keyRangeQuery, storeManager.getPageSize());
    }
View Full Code Here

TOP

Related Classes of com.thinkaurelius.titan.diskstorage.PermanentStorageException

Copyright © 2018 www.massapicom. 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.