15 Commits

Author SHA1 Message Date
Gyu-Ho Lee
4a5befc2de wal: update LICENSE header 2016-05-12 20:50:04 -07:00
Anthony Romano
774030e1b2 wal: repair torn writes
Fixes #5230
2016-05-06 16:54:08 -07:00
Anthony Romano
bfe3a3d08e wal: fix tail corruption
On ReadAll, WAL seeks to the end of the last record in the tail. If the tail did not
end with preallocated space, the decoder would report 0 as the last offset and begin
writing at offset 0 of the tail.

Fixes #4903
2016-04-01 15:05:52 -07:00
Anthony Romano
24b806d2ee wal: preallocate WAL files with initial size equal to segment size
Avoids having to update file size metadata during fdatasync on common path.

Fixes #4755
2016-03-21 11:56:53 -07:00
Anthony Romano
7397e14c0a fileutil, wal: refactor file locking
File lock interface was more verbose than it needed to be while
simultaneously making it difficult to support systems (e.g., Windows)
that only permit locked writes on a single fd holding the lock.
2016-03-16 15:02:15 -07:00
Xiang Li
d1d7feacc9 wal: change io.EOF returned by readFull to io.ErrUnexpectedEOF
Decoder should return error for any broken block including the
one that only contains the length field. We should change io.EOF
to io.ErrUnexpectedEOF before return the error.
2015-04-23 09:53:36 -07:00
Xiang Li
ab72c3ec88 wal: do not race reader and writer 2015-03-05 20:19:17 -08:00
Jonathan Boulle
f1ed69e883 *: switch to line comments for copyright
Build tags are not compatible with block comments.
Also adds copyright header to a few places it was missing.
2015-01-26 09:53:30 -08:00
Jonathan Boulle
7a4d42166b *: add license header to all source files 2014-10-17 15:41:22 -07:00
Xiang Li
f98fbbfc14 *: proto refactoring 2014-10-14 21:07:23 +08:00
Yicheng Qin
447caf1afc etcdserver/wal: record info at the head of WAL file 2014-10-10 11:57:09 -07:00
Xiang Li
2f6086de22 pkg: move /crc to /pkg/crc 2014-09-25 10:50:33 -07:00
Yicheng Qin
023dc7cba2 etcdserver: add SYNC request 2014-09-16 13:42:03 -07:00
Xiang Li
b98cf17209 wal: move pb files to walpb 2014-09-03 16:46:42 -07:00
Xiang Li
bdb954b2f5 wal: fix wal 2014-09-03 15:10:15 -07:00