From e4e0840f17b1961ad1826699a8993d06ccfbc75a Mon Sep 17 00:00:00 2001 From: "Brian S. O'Neill" Date: Sat, 2 Apr 2011 16:41:50 +0000 Subject: Add support to specify log region size. Patch provided by Michael Roberts. --- .../repo/sleepycat/BDBRepositoryBuilder.java | 23 ++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java b/src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java index 4df17f5..6def603 100644 --- a/src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java +++ b/src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java @@ -94,6 +94,7 @@ public final class BDBRepositoryBuilder extends AbstractRepositoryBuilder { private boolean mReadOnly; private Long mCacheSize; private Integer mCachePercent; + private Integer mLogRegionSize; private double mLockTimeout = 0.5; private Integer mMaxLocks; private double mTxnTimeout = 300.0; @@ -521,6 +522,28 @@ public final class BDBRepositoryBuilder extends AbstractRepositoryBuilder { return mCacheSize; } + /** + * Set the repository log region size, in bytes. + */ + public void setLogRegionSize(int logRegionSize) { + mLogRegionSize = logRegionSize; + } + + /** + * Set the repository log region size, in bytes. + */ + public void setLogRegionSize(Integer logRegionSize) { + mLogRegionSize = logRegionSize; + } + + /** + * Returns the repository log region size, or null if the default + * should be selected. + */ + public Integer getLogRegionSize() { + return mLogRegionSize; + } + /** * Set the percent of JVM heap used by the repository cache. Actual * BDB implementation will select a suitable default if this is not -- cgit v1.2.3