diff options
author | Brian S. O'Neill <bronee@gmail.com> | 2006-10-14 17:22:20 +0000 |
---|---|---|
committer | Brian S. O'Neill <bronee@gmail.com> | 2006-10-14 17:22:20 +0000 |
commit | 4ceddfc456e83a79e782599b5b86b68e38b6ef94 (patch) | |
tree | d8ae12fed26e3203f6e88b9e415d6cdc3877b0b6 /src/main/java/com/amazon | |
parent | b044b17b7c455d6f23b0a4f8da7550d997036caa (diff) |
Added support for memory-only transaction logs.
Diffstat (limited to 'src/main/java/com/amazon')
-rw-r--r-- | src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java | 17 |
1 files changed, 17 insertions, 0 deletions
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 3a6d476..695f520 100644 --- a/src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java +++ b/src/main/java/com/amazon/carbonado/repo/sleepycat/BDBRepositoryBuilder.java @@ -95,6 +95,7 @@ public class BDBRepositoryBuilder extends AbstractRepositoryBuilder { private Map<Class<?>, Integer> mDatabasePageSizes;
private boolean mPrivate;
private boolean mMultiversion;
+ private boolean mLogInMemory;
private boolean mRunCheckpointer = true;
private int mCheckpointInterval = DEFAULT_CHECKPOINT_INTERVAL;
private boolean mRunDeadlockDetector = true;
@@ -506,6 +507,22 @@ public class BDBRepositoryBuilder extends AbstractRepositoryBuilder { }
/**
+ * Set true to store transaction logs in memory only instead of persistent
+ * storage. For BDB products which are entirely log based, no records are
+ * ever persisted.
+ */
+ public void setLogInMemory(boolean logInMemory) {
+ mLogInMemory = true;
+ }
+
+ /**
+ * Returns false by default, indicating that transaction logs are persisted.
+ */
+ public boolean getLogInMemory() {
+ return mLogInMemory;
+ }
+
+ /**
* Disable automatic checkpointing of database if another process is
* responsible for that. The false setting is implied for read-only
* databases.
|