Deprecated List (Oracle - Berkeley DB Java Edition API)
Date: 2014-12-16

# Deprecated API

## Contents

- Deprecated Classes
- Deprecated Exceptions
- Deprecated Fields
- Deprecated Methods
- Deprecated Constructors

- Deprecated Classes
  Class and Description
  com.sleepycat.je.jmx.JEMBeanHelper As of JE 4, JEMBeanHelper is deprecated in favor of the concrete MBeans available by default with a JE environment. These MBeans can be registered and enabled by the environment by setting the following JVM property: JEMonitor: This MBean provides general stats monitoring and access to basic environment level operations. JEMBeanHelper is a utility class for the MBean implementation which wants to add management of a JE environment to its capabilities. MBean implementations can contain a JEMBeanHelper instance to get MBean metadata for JE and to set attributes, get attributes, and invoke operations. com.sleepycat.je.jmx.JEMonitor and the example program jmx.JEApplicationMBean are two MBean implementations which provide support different application use cases. See those classes for examples of how to use JEMBeanHelper.
  com.sleepycat.je.LockStats as of 4.0.10, replaced by `Environment.getStats(StatsConfig)`.

- Deprecated Exceptions
  Exceptions and Description
  com.sleepycat.je.DeadlockException temporarily until true deadlock detection is implemented. Presently, {code DeadlockException} is replaced by `LockConflictException` as the common base class for lock conflict exceptions.
  com.sleepycat.je.LockNotGrantedException replaced by `LockNotAvailableException`
  com.sleepycat.je.rep.MasterReplicaTransitionException as of JE 5.0.88 because the environment no longer needs to restart when transitioning from master to replica.
  com.sleepycat.je.RunRecoveryException replaced by `EnvironmentFailureException` and `Environment.isValid()`.

- Deprecated Fields
  Field and Description
  com.sleepycat.je.EnvironmentConfig.CLEANER_BACKGROUND_PROACTIVE_MIGRATION This parameter is ignored and proactive migration is no longer supported due to its negative impact on eviction and checkpointing. To reduce a cleaner backlog, configure more cleaner threads.
  com.sleepycat.je.EnvironmentConfig.CLEANER_FOREGROUND_PROACTIVE_MIGRATION This parameter is ignored and proactive migration is no longer supported due to its negative impact on eviction and Btree splits. To reduce a cleaner backlog, configure more cleaner threads.
  com.sleepycat.je.EnvironmentConfig.CLEANER_LAZY_MIGRATION This parameter is ignored and lazy migration is no longer supported due to its negative impact on eviction and checkpointing. To reduce a cleaner backlog, configure more cleaner threads.
  com.sleepycat.je.EnvironmentConfig.COMPRESSOR_PURGE_ROOT as of 3.3.87. Compression of the root node no longer has any benefit and this feature has been removed. This parameter has no effect.
  com.sleepycat.je.EnvironmentConfig.EVICTOR_DEADLOCK_RETRY as of JE 4.1, since the single evictor thread has been replaced be a more robust thread pool. The number of times to retry the evictor if it runs into a deadlock. When using the shared cache feature, the value of this property is applied the first time the cache is set up. New environments that join the cache do not alter the cache setting.
  Name | Type | Mutable | Default | Minimum | Maximum
  "je.evictor.deadlockRetry" | Integer | No | 3 | 0 | -none-
  com.sleepycat.je.EnvironmentConfig.EVICTOR_LRU_ONLY as of JE 6.0. This parameter is ignored by the new, more efficient and more accurate evictor. If true (the default), use an LRU-only policy to select nodes for eviction. If false, select by Btree level first, and then by LRU. When using the shared cache feature, the value of this property is applied the first time the cache is set up. New environments that join the cache do not alter the cache setting.
  Name | Type | Mutable | Default
  "je.evictor.lruOnly" | Boolean | No | true
  com.sleepycat.je.EnvironmentConfig.EVICTOR_NODES_PER_SCAN as of JE 6.0. This parameter is ignored by the new, more efficient and more accurate evictor. The number of nodes in one evictor scan. When using the shared cache feature, the value of this property is applied the first time the cache is set up. New environments that join the cache do not alter the cache setting.
  Name | Type | Mutable | Default | Minimum | Maximum
  "je.evictor.nodesPerScan" | Integer | No | 10 | 1 | 1000
  com.sleepycat.je.rep.ReplicationConfig.HELPER_HOSTS replaced by `ReplicationMutableConfig.HELPER_HOSTS`.
  com.sleepycat.je.EnvironmentConfig.LOG_CHUNKED_NIO NIO is no longer used by JE and this parameter has no effect.
  com.sleepycat.je.EnvironmentConfig.LOG_DIRECT_NIO NIO is no longer used by JE and this parameter has no effect.
  com.sleepycat.je.EnvironmentConfig.LOG_USE_NIO NIO is no longer used by JE and this parameter has no effect.
  com.sleepycat.je.EnvironmentConfig.NODE_DUP_TREE_MAX_ENTRIES this property no longer has any effect; `DatabaseConfig.setNodeMaxEntries(int)` should be used instead.
  com.sleepycat.je.Durability.READ_ONLY_TXN use `TransactionConfig.setReadOnly(boolean)` instead.
  com.sleepycat.je.rep.ReplicationConfig.REPLAY_DB_HANDLE_TIMEOUT replaced by `ReplicationMutableConfig.REPLAY_DB_HANDLE_TIMEOUT`.
  com.sleepycat.je.rep.ReplicationConfig.REPLAY_MAX_OPEN_DB_HANDLES replaced by `ReplicationMutableConfig.REPLAY_MAX_OPEN_DB_HANDLES`.
  com.sleepycat.je.EnvironmentConfig.TRACE_CONSOLE in favor of `CONSOLE_LOGGING_LEVEL` As of JE 4.0, use the standard java.util.logging configuration methodologies. To enable console output, set com.sleepycat.je.util.ConsoleHandler.level = <LEVEL> through the java.util.logging configuration file, or through the java.util.logging.LogManager. To set the handler level programmatically, set "com.sleepycat.je.util.ConsoleHandler.level" in the EnvironmentConfig object.
  com.sleepycat.je.EnvironmentConfig.TRACE_DB As of JE 4.0, event tracing to the .jdb files has been separated from the java.util.logging mechanism. This parameter has no effect.
  com.sleepycat.je.EnvironmentConfig.TRACE_FILE in favor of `FILE_LOGGING_LEVEL` As of JE 4.0, use the standard java.util.logging configuration methodologies. To enable logging output to the je.info files, set com.sleepycat.je.util.FileHandler.level = <LEVEL> through the java.util.logging configuration file, or through the java.util.logging.LogManager. To set the handler level programmatically, set "com.sleepycat.je.util.FileHandler.level" in the EnvironmentConfig object.
  com.sleepycat.je.EnvironmentConfig.TRACE_FILE_COUNT As of JE 4.0, use the standard java.util.logging configuration methodologies. To set the FileHandler output file count, set com.sleepycat.je.util.FileHandler.count = <NUMBER> through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TRACE_FILE_LIMIT As of JE 4.0, use the standard java.util.logging configuration methodologies. To set the FileHandler output file size, set com.sleepycat.je.util.FileHandler.limit = <NUMBER> through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TRACE_LEVEL As of JE 4.0, use the standard java.util.logging configuration methodologies. Set logging levels using class names through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TRACE_LEVEL_CLEANER As of JE 4.0, use the standard java.util.logging configuration methodologies. To see cleaner logging, set com.sleepycat.je.cleaner.level = <LEVEL> through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TRACE_LEVEL_EVICTOR As of JE 4.0, use the standard java.util.logging configuration methodologies. To see evictor logging, set com.sleepycat.je.evictor.level = <LEVEL> through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TRACE_LEVEL_LOCK_MANAGER As of JE 4.0, use the standard java.util.logging configuration methodologies. To see locking logging, set com.sleepycat.je.txn.level = <LEVEL> through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TRACE_LEVEL_RECOVERY As of JE 4.0, use the standard java.util.logging configuration methodologies. To see recovery logging, set com.sleepycat.je.recovery.level = <LEVEL> through the java.util.logging configuration file, or through the java.util.logging.LogManager.
  com.sleepycat.je.EnvironmentConfig.TREE_MAX_DELTA as of JE 6.0. The `EnvironmentConfig.TREE_BIN_DELTA` param alone now determines whether a delta is logged.

- Deprecated Methods
  Method and Description
  com.sleepycat.persist.model.EntityModel.classForName(String) use `EntityModel.resolveClass(java.lang.String)` instead. This method does not use the environment's ClassLoader property.
  com.sleepycat.je.DatabaseConfig.cloneConfig() As of JE 4.0.13, replaced by `DatabaseConfig.clone()`.
  com.sleepycat.persist.StoreConfig.cloneConfig() As of JE 4.0.13, replaced by `StoreConfig.clone()`.
  com.sleepycat.persist.evolve.EvolveConfig.cloneConfig() As of JE 4.0.13, replaced by `EvolveConfig.clone()`.
  com.sleepycat.je.SecondaryCursor.dupSecondary(boolean) As of JE 4.0.13, replaced by `Cursor.dup(boolean)`.
  com.sleepycat.je.EnvironmentStats.getAvgBatchCacheMode() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getAvgBatchCritical() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getAvgBatchDaemon() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getAvgBatchEvictorThread() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getAvgBatchManual() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getCacheDataBytes() Please use `EnvironmentStats.getDataBytes()` to get the amount of cache used for data and use `EnvironmentStats.getAdminBytes()`, `EnvironmentStats.getLockBytes()` and `EnvironmentStats.getBufferBytes()` to get other components of the total cache usage (`EnvironmentStats.getCacheTotalBytes()`).
  com.sleepycat.je.EnvironmentStats.getCorrectedAvgLNSize() in JE 5.0.56, use `EnvironmentStats.getCorrectedAvgLNSize()` instead.
  com.sleepycat.je.BtreeStats.getDBINsByLevel() as of 5.0, returns an empty array.
  com.sleepycat.util.ExceptionWrapper.getDetail() replaced by `ExceptionWrapper.getCause()`.
  com.sleepycat.util.RuntimeExceptionWrapper.getDetail() replaced by `Throwable.getCause()`.
  com.sleepycat.util.IOExceptionWrapper.getDetail() replaced by `IOExceptionWrapper.getCause()`.
  com.sleepycat.je.BtreeStats.getDINsByLevel() as of 5.0, returns an empty array.
  com.sleepycat.je.BtreeStats.getDupCountLeafNodeCount() as of 5.0, returns zero.
  com.sleepycat.je.BtreeStats.getDuplicateBottomInternalNodeCount() as of 5.0, returns zero.
  com.sleepycat.je.BtreeStats.getDuplicateInternalNodeCount() as of 5.0, returns zero.
  com.sleepycat.je.BtreeStats.getDuplicateTreeMaxDepth() as of 5.0, returns zero.
  com.sleepycat.je.EnvironmentStats.getEstimatedAvgLNSize() in JE 5.0.56, use `EnvironmentStats.getCorrectedAvgLNSize()` instead.
  com.sleepycat.je.Environment.getLockStats(StatsConfig) as of 4.0.10, replaced by `Environment.getStats(StatsConfig)`.
  com.sleepycat.je.EnvironmentConfig.getLockTimeout() as of 4.0, replaced by `EnvironmentConfig.getLockTimeout(TimeUnit)`.
  com.sleepycat.je.util.DbBackup.getLogFilesInBackupSet(long) replaced by `DbBackup.getLogFilesInBackupSet()`; pass lastFileInPrevBackup to the `DbBackup.DbBackup(Environment,long)` constructor.
  com.sleepycat.je.DiskOrderedCursorConfig.getMaxSeedMillisecs() this method returns zero and will be removed in a future release.
  com.sleepycat.je.DiskOrderedCursorConfig.getMaxSeedNodes() this method returns zero and will be removed in a future release.
  com.sleepycat.je.EnvironmentStats.getNBatchesCacheMode() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBatchesCritical() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBatchesDaemon() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBatchesEvictorThread() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBatchesManual() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBINsEvictedCacheMode() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBINsEvictedCritical() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBINsEvictedDaemon() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBINsEvictedEvictorThread() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBINsEvictedManual() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNBINsMutated() Use getNNodesMutated() instead.
  com.sleepycat.je.EnvironmentStats.getNBINsStripped() Use getNNodesStripped() instead.
  com.sleepycat.je.PreloadStats.getNDBINsLoaded() returns zero for data written using JE 5.0 and later, but may return non-zero values when reading older data.
  com.sleepycat.je.PreloadStats.getNDINsLoaded() returns zero for data written using JE 5.0 and later, but may return non-zero values when reading older data.
  com.sleepycat.je.PreloadStats.getNDupCountLNsLoaded() returns zero for data written using JE 5.0 and later, but may return non-zero values when reading older data.
  com.sleepycat.je.EnvironmentStats.getNEvictPasses() Use getNEvictionRuns() instead.
  com.sleepycat.je.EnvironmentStats.getNNodesExplicitlyEvicted() Use getNNodesEvicted() instead.
  com.sleepycat.je.EnvironmentStats.getNNodesScanned() This statistic has no meaning after the implementation of the new evictor in JE 6.0. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNNodesSelected() Use getNNodesTargeted() instead.
  com.sleepycat.je.DatabaseConfig.getNodeMaxDupTreeEntries() this property no longer has any effect and zero is always returned; `DatabaseConfig.getNodeMaxEntries()` should be used instead.
  com.sleepycat.je.TransactionConfig.getNoSync() replaced by `TransactionConfig.getDurability()`
  com.sleepycat.je.EnvironmentStats.getNUpperINsEvictedCacheMode() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNUpperINsEvictedCritical() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNUpperINsEvictedDaemon() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNUpperINsEvictedEvictorThread() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getNUpperINsEvictedManual() This statistic has been removed. The method returns 0 always.
  com.sleepycat.je.EnvironmentStats.getRequiredEvictBytes() The method returns 0 always.
  com.sleepycat.je.SecondaryDatabase.getSecondaryConfig() As of JE 4.0.13, replaced by `SecondaryDatabase.getConfig()`.
  com.sleepycat.je.EnvironmentMutableConfig.getTxnNoSync() replaced by `EnvironmentMutableConfig.getDurability()`
  com.sleepycat.je.EnvironmentConfig.getTxnTimeout() as of 4.0, replaced by `EnvironmentConfig.getTxnTimeout(TimeUnit)`.
  com.sleepycat.je.EnvironmentMutableConfig.getTxnWriteNoSync() replaced by `EnvironmentMutableConfig.getDurability()`
  com.sleepycat.je.TransactionConfig.getWriteNoSync() replaced by `TransactionConfig.getDurability()`
  com.sleepycat.collections.StoredCollection.iterator(boolean) Please use `StoredCollection.storedIterator()` or `StoredCollection.storedIterator(boolean)` instead. Because the iterator returned must be closed, the method name `iterator` is confusing since standard Java iterators do not need to be closed.
  com.sleepycat.bind.tuple.TupleBase.newOutput() replaced by `TupleBase.getTupleOutput(E)`
  com.sleepycat.bind.tuple.TupleBase.newOutput(byte[]) replaced by `TupleBase.getTupleOutput(E)`
  com.sleepycat.je.SecondaryDatabase.openSecondaryCursor(Transaction, CursorConfig) As of JE 4.0.13, replaced by `SecondaryDatabase.openCursor(com.sleepycat.je.Transaction, com.sleepycat.je.CursorConfig)`.
  com.sleepycat.je.Database.preload(long) As of JE 2.0.83, replaced by `Database.preload(PreloadConfig)`.
  com.sleepycat.je.Database.preload(long, long) As of JE 2.0.101, replaced by `Database.preload(PreloadConfig)`.
  com.sleepycat.je.EnvironmentConfig.setLockTimeout(long) as of 4.0, replaced by `EnvironmentConfig.setLockTimeout(long, TimeUnit)`.
  com.sleepycat.je.Transaction.setLockTimeout(long) as of 4.0, replaced by `Transaction.setLockTimeout(long, TimeUnit)`.
  com.sleepycat.je.DiskOrderedCursorConfig.setMaxSeedMillisecs(long) this method has no effect and will be removed in a future release.
  com.sleepycat.je.DiskOrderedCursorConfig.setMaxSeedNodes(long) this method has no effect and will be removed in a future release.
  com.sleepycat.je.DatabaseConfig.setNodeMaxDupTreeEntries(int) this property no longer has any effect; `DatabaseConfig.setNodeMaxEntries(int)` should be used instead.
  com.sleepycat.je.TransactionConfig.setNoSync(boolean) replaced by `TransactionConfig.setDurability(com.sleepycat.je.Durability)`
  com.sleepycat.je.EnvironmentMutableConfig.setTxnNoSync(boolean) replaced by `EnvironmentMutableConfig.setDurability(com.sleepycat.je.Durability)`
  com.sleepycat.je.EnvironmentConfig.setTxnTimeout(long) as of 4.0, replaced by `EnvironmentConfig.setTxnTimeout(long, TimeUnit)`.
  com.sleepycat.je.Transaction.setTxnTimeout(long) as of 4.0, replaced by `Transaction.setTxnTimeout(long, TimeUnit)`.
  com.sleepycat.je.EnvironmentMutableConfig.setTxnWriteNoSync(boolean) replaced by `EnvironmentMutableConfig.setDurability(com.sleepycat.je.Durability)`
  com.sleepycat.je.TransactionConfig.setWriteNoSync(boolean) replaced by `TransactionConfig.setDurability(com.sleepycat.je.Durability)`

- Deprecated Constructors
  Constructor and Description
  com.sleepycat.je.util.DbDump(Environment, String, PrintStream, String, boolean) Please use the 4-arg ctor without outputDirectory instead.
  com.sleepycat.je.rep.monitor.Monitor(ReplicationConfig) As of JE 5, replaced by `Monitor.Monitor(MonitorConfig)`

Copyright (c) 2004, 2014 Oracle and/or its affiliates. All rights reserved.