| | |
| | | { |
| | | exchange.remove(); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | bytesToValue(ex.getValue(), value); |
| | | ex.store(); |
| | | } |
| | | catch (final Exception e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | bytesToKey(ex.getKey(), key); |
| | | return ex.remove(); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | ex = getExchangeFromCache(treeName); |
| | | ex.removeTree(); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | */ |
| | | return new CursorImpl(getNewExchange(treeName, false)); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | { |
| | | getExchangeFromCache(treeName); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | ex.fetch(); |
| | | return valueToBytes(ex.getValue()); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | } |
| | | return false; |
| | | } |
| | | catch (final Exception e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | put(treeName, dummyKey, ByteString.empty()); |
| | | delete(treeName, dummyKey); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | { |
| | | // ignore missing trees. |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |
| | |
| | | catch(final InUseException e) { |
| | | throw new StorageInUseException(e); |
| | | } |
| | | catch (final PersistitException e) |
| | | catch (final PersistitException | RollbackException e) |
| | | { |
| | | throw new StorageRuntimeException(e); |
| | | } |