35 Commits

Author SHA1 Message Date
Ben Johnson
59fde2f664 Error refactoring.
Fixed up a few error issues and refactored out the Error type.
2014-03-24 08:31:15 -06:00
Ben Johnson
482f00fdfc Add ErrTxClosed error.
Commit/Rollback and mutable calls on Tx and Bucket now return ErrTxClosed
if the transaction has already been committed or rolled back. Non-mutable
calls have added an assertion to check if the transaction is closed which
will cause a panic. I don't want to introduce an error return for accessor
methods that are being used improperly so I think the panic is appropriate.
2014-03-23 12:20:16 -06:00
binz
540d94614d fix 32bit build fails: bucket.go#67 2014-03-23 13:54:51 +08:00
Ben Johnson
1c7b59a4c2 Merge pull request #65 from benbjohnson/fix-tx-buckets-sort-order
Fix Tx.Buckets() sort order.
2014-03-21 08:45:34 -06:00
Ben Johnson
26afa92faf Fix Bucket.ForEach() comment. 2014-03-15 09:14:20 -06:00
Ben Johnson
62cf02e21a Fix Tx.Buckets() sort order.
@tv42 reported an issue with bucket names returning incorrectly. Not sure if
this fixes the issue but it is necessary anyway.
2014-03-13 15:08:59 -06:00
Ben Johnson
c551e45a47 Consolidate Tx and RWTx. 2014-03-08 20:40:48 -07:00
Ben Johnson
57376f0905 Rename Transaction to Tx.
I changed the Transaction/RWTransaction types to Tx/RWTx, respectively. This makes the naming
more consistent with other packages such as database/sql. The txnid is changed to txid as well.
2014-03-08 17:04:02 -07:00
Ben Johnson
a1f43f4d60 Allow reads of unflushed nodes.
This commit allows cursors to read updated values from within the
RWTransaction.
2014-03-01 09:13:59 -07:00
Ben Johnson
a544249dd8 Refactor Bucket. 2014-02-23 08:32:53 -07:00
Ben Johnson
3b2fd8f2d3 Revert "Refactor Transaction/Bucket API."
This reverts commit 1ad2b99f281d587b767b36f886401e81d17915a9.
2014-02-22 22:54:54 -07:00
Ben Johnson
1ad2b99f28 Refactor Transaction/Bucket API. 2014-02-21 22:57:50 -07:00
Ben Johnson
1028d571d8 Bucket stats. 2014-02-21 09:20:45 -07:00
Ben Johnson
7fb06feea4 Add parallel usage test and race detector. 2014-02-15 21:50:34 -07:00
Ben Johnson
e68bc0b453 Add bucket sequence. 2014-02-15 10:23:00 -07:00
Ben Johnson
8ad59edd02 API Documentation. 2014-02-13 10:58:27 -07:00
Ben Johnson
509e93dff4 Add freelist. 2014-02-10 14:04:01 -07:00
Ben Johnson
9ebfc171b3 Clean up. 2014-02-09 14:23:22 -07:00
Ben Johnson
84939c21f6 Refactor node lookup. 2014-02-07 15:03:29 -07:00
Ben Johnson
1a17a2cf1e Add RWTransaction.Put(). 2014-02-01 12:30:37 -05:00
Ben Johnson
a901cf6a25 Clean up API. 2014-01-31 12:22:58 -05:00
Ben Johnson
26f6fefead Add RWTransaction.write(). 2014-01-30 22:20:50 -05:00
Ben Johnson
8d5757e9dd gofmt 2014-01-30 17:04:56 -05:00
Ben Johnson
149d48fb9e Fix leaf/branch deserialization. 2014-01-30 00:11:46 -05:00
Ben Johnson
4ad445aa85 Add freelist page type. 2014-01-29 22:50:29 -05:00
Ben Johnson
192649f453 Intermediate. 2014-01-27 10:11:54 -05:00
Ben Johnson
1baa6d576a Initialize transaction/rwtransaction. 2014-01-26 15:29:06 -07:00
Ben Johnson
73ab1d420d TODO 2014-01-24 16:32:18 -07:00
Ben Johnson
bce3e667df Intermediate commit. 2014-01-21 15:00:48 -07:00
Ben Johnson
153372abd4 Refactoring to RWCursor, RWTxn, and branch/leaf nodes and pages. 2014-01-17 15:23:39 -07:00
Ben Johnson
cec7b942e7 Add system buckets. 2014-01-14 13:01:02 -07:00
Ben Johnson
79d9b6bb5a Begin Transaction.Cursor(). 2014-01-13 10:35:04 -07:00
Ben Johnson
ee24437bfc Initial db.open. 2014-01-11 22:51:01 -07:00
Ben Johnson
df8333328f DB.Open(), pages, and meta. 2014-01-10 07:32:12 -07:00
Ben Johnson
ebc9f0da9e Basic types. 2014-01-08 08:06:17 -07:00