HBASE-2041 Change WAL default configuration values

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@890547 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jean-Daniel Cryans 2009-12-14 23:16:05 +00:00
parent 6965cf5135
commit cacce6c5f6
3 changed files with 7 additions and 7 deletions

View File

@ -171,16 +171,16 @@
</property>
<property>
<name>hbase.regionserver.flushlogentries</name>
<value>100</value>
<value>1</value>
<description>Sync the HLog to the HDFS when it has accumulated this many
entries. Default 100. Value is checked on every HLog.append
entries. Default 1. Value is checked on every HLog.hflush
</description>
</property>
<property>
<name>hbase.regionserver.optionallogflushinterval</name>
<value>10000</value>
<value>1000</value>
<description>Sync the HLog to the HDFS after this interval if it has not
accumulated enough entries to trigger a sync. Default 10 seconds. Units:
accumulated enough entries to trigger a sync. Default 1 second. Units:
milliseconds.
</description>
</property>

View File

@ -95,7 +95,7 @@ public class HTableDescriptor implements WritableComparable<HTableDescriptor> {
public static final int DEFAULT_MAX_FILESIZE = 1024*1024*256;
public static final boolean DEFAULT_DEFERRED_LOG_FLUSH = false;
public static final boolean DEFAULT_DEFERRED_LOG_FLUSH = true;
private volatile Boolean meta = null;
private volatile Boolean root = null;

View File

@ -215,7 +215,7 @@ public class HLog implements HConstants, Syncable {
this.conf = conf;
this.listener = listener;
this.flushlogentries =
conf.getInt("hbase.regionserver.flushlogentries", 100);
conf.getInt("hbase.regionserver.flushlogentries", 1);
this.blocksize = conf.getLong("hbase.regionserver.hlog.blocksize",
this.fs.getDefaultBlockSize());
this.replicationLevel = (short) conf.getInt("hbase.regionserver.hlog.replication",
@ -224,7 +224,7 @@ public class HLog implements HConstants, Syncable {
float multi = conf.getFloat("hbase.regionserver.logroll.multiplier", 0.95f);
this.logrollsize = (long)(this.blocksize * multi);
this.optionalFlushInterval =
conf.getLong("hbase.regionserver.optionallogflushinterval", 10 * 1000);
conf.getLong("hbase.regionserver.optionallogflushinterval", 1 * 1000);
if (fs.exists(dir)) {
throw new IOException("Target HLog directory already exists: " + dir);
}