Commit Graph

10 Commits (514ec57fe7d7855cafc2599bbce43646a19b417c)

Author SHA1 Message Date
Xiang Li b986966361 add WriteToFlag to Tx
For in memory workload, it does not make sense to use
o_direct to copy the file. Adding a option to clear out
o_direct and for other future cases.
2015-11-06 11:03:28 -08:00
James Tucker 1cb787ee7b windows: implement file locking 2015-09-16 09:28:26 -03:00
sasha-s aa13f7f94f make ignoring Truncate() explicit
https://github.com/boltdb/bolt/pull/371#issuecomment-103176330
2015-05-18 12:00:40 -07:00
sasha-s fda75748b5 use a shared lock in read-only mode
https://github.com/boltdb/bolt/pull/371#issuecomment-103119486
2015-05-18 11:07:19 -07:00
sasha-s 019bf5b010 open read-only databases in read-only mode 2015-05-14 15:43:13 -07:00
Josh Rickmar a2cbaa05f9 Fix bolt on OpenBSD.
OpenBSD does not include a UBC kernel and writes must be synchronized
with the msync(2) syscall.  In addition, the NoSync field of the DB
struct should be ignored on OpenBSD, since unlike other platforms,
missing msyncs will result in data corruption.

Depends on PR #258.

Fixes #257.
2014-09-18 18:14:50 -05:00
Casey Marshall 1409473547 Fixed cast for 32-bit windows. 2014-07-13 03:14:27 -05:00
Ben Johnson 00ee0da528 Add Open() options, flock timeout.
This commit changes Open() to provide an additional Options argument. The options
argument currently only has a Timeout which will cause the Open() to return
ErrTimeout if a file lock cannot be obtained in time.

Fixes #207.
2014-06-21 14:44:28 -06:00
Ben Johnson 1c97a490dd Add Windows support.
This commit adds Windows support to Bolt. Windows memory maps return an address instead of a byte
slice so the DB.data field had to be refactored to be a pointer to a large byte array.
2014-06-12 09:23:30 -06:00
Ben Johnson c2577db1c2 Add Windows support. 2014-06-11 11:11:21 -06:00