coreos/etcd — pull request #1130 by jonboulle (2014-09-23 02:09:22+00:00)
Title: wal logs saveState too frequently

Started etcd (on existing data dir) with no clients and etcd starting printing a commit line every second:

```
2014/09/22 13:35:16 main: no data-dir is given, using default data-dir ./0x1_etcd_data
2014/09/22 13:35:16 path=0x1_etcd_data/wal wal.load index=0
2014/09/22 13:35:16 Listening for peers on :7001
2014/09/22 13:35:16 Listening for client requests on 127.0.0.1:4001
2014/09/22 13:35:17 raft: leader changed from 0x0 to 0x1
2014/09/22 13:35:17 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:88 "
2014/09/22 13:35:17 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:89 "
2014/09/22 13:35:18 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:90 "
2014/09/22 13:35:18 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:91 "
2014/09/22 13:35:19 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:92 "
2014/09/22 13:35:19 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:93 "
2014/09/22 13:35:20 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:94 "
2014/09/22 13:35:20 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:95 "
2014/09/22 13:35:21 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:96 "
2014/09/22 13:35:21 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:97 "
2014/09/22 13:35:22 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:98 "
2014/09/22 13:35:22 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:99 "
2014/09/22 13:35:23 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:100 "
2014/09/22 13:35:23 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:101 "
2014/09/22 13:35:24 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:102 "
2014/09/22 13:35:24 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:103 "
2014/09/22 13:35:25 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:104 "
2014/09/22 13:35:25 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:105 "
2014/09/22 13:35:26 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:106 "
2014/09/22 13:35:26 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:107 "
2014/09/22 13:35:27 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:108 "
2014/09/22 13:35:27 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:109 "
2014/09/22 13:35:28 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:110 "
2014/09/22 13:35:28 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:111 "
2014/09/22 13:35:29 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:112 "
2014/09/22 13:35:29 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:113 "
2014/09/22 13:35:30 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:114 "
2014/09/22 13:35:30 path=0x1_etcd_data/wal/0000000000000000-0000000000000000.wal wal.saveState state="term:8 vote:0 commit:115 "
```