Package com.foundationdb.server.error

Examples of com.foundationdb.server.error.DuplicateKeyException


            txn.getIndexChecks(false) == null) {
            check.blockUntilReady(txn);
            if (!check.check(session, txn, index)) {
                // Using RowData, can give better error than check.throwException().
                String msg = formatIndexRowString(session, rowData, index);
                throw new DuplicateKeyException(index.getIndexName(), msg);
            }
        }
        else {
            txn.getIndexChecks(false).add(session, txn, index, check);
        }
View Full Code Here


                existed = iEx.traverse(Key.Direction.EQ, true, -1);
            }
            if (existed) {
                LOG.debug("Duplicate key for index {}, raw: {}", index.getIndexName(), key);
                String msg = formatIndexRowString(session, rowData, index);
                throw new DuplicateKeyException(index.getIndexName(), msg);
            }
        }
    }
View Full Code Here

        public RuntimeException createException(Session session, TransactionState txn, Index index) {
            // Recover Key for error message.
            Key persistitKey = new Key((Persistit)null);
            FDBStoreDataHelper.unpackTuple(index, persistitKey, bkey);
            String msg = formatIndexRowString(index, persistitKey);
            return new DuplicateKeyException(index.getIndexName(), msg);
        }
View Full Code Here

TOP

Related Classes of com.foundationdb.server.error.DuplicateKeyException

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.