Commit graph

18 commits

Author SHA1 Message Date
Dave Collins
1b4d499597 Update btcwire import paths to new location. 2015-01-16 13:59:18 -06:00
Dave Collins
97f3917fcf Update goleveldb import paths to new location.
Also update for changes due to the upstream sync.
2015-01-15 03:16:32 -06:00
John C. Vernaleo
a7ac93f5b6 Error improvements for lint.
Rename errors to Err*.
Lowercase error text.

Add golint for top level package

ok @davecgh
2014-09-16 15:07:11 -04:00
Dave Collins
16dc2cf2d0 Add errors to all interface methods.
This commit adds error returns to all of the Db interface methods except
for FetchTxByShaList and FetchUnSpentTxByShaList since they expose the
errors on each individual transaction.

It also updates all tests and code for both the leveldb and memdb drivers
for the changes.

Closes #5.

ok @drahn
2014-07-07 12:55:46 -05:00
David Hill
d31183ff19 go fmt 2014-07-07 11:07:30 -04:00
David Hill
0dd81ad003 Use NewReader instead of NewBuffer.
NewReader is slightly faster than NewBuffer, but more importantly,
ensures the data is read-only.
2014-07-07 11:05:02 -04:00
David Hill
e2628dfc0d convert binary Read/Write to Uint/PutUint and copy 2014-07-07 11:05:00 -04:00
Dave Collins
efb92fcc99 goimports -w . 2014-07-02 19:47:24 -05:00
David Hill
b40f5a1b24 add missing Lock to FetchTxBySha 2014-05-30 15:03:39 -04:00
Dale Rahn
dd41d71a31 If data for tx is not present, return error. 2014-04-15 10:47:25 -04:00
Dale Rahn
4d63076526 All external entry points into the database must be locked. 2014-04-15 10:17:37 -04:00
Dave Collins
6b18796af7 Add 2014 to copyright dates. 2014-01-08 23:54:52 -06:00
Dave Collins
fc11da9ca0 Gofmt. 2013-11-21 09:48:57 -06:00
Dale Rahn
e10cb732fd Fix. 2013-11-07 18:24:27 -05:00
Dale Rahn
13ef0e2be9 Rework leveldb support for duplicate tx.
This separates fully spent tx from tx containing unspent TxOut
This handles duplicate tx and Ideally should be faster.
2013-11-05 13:44:36 -05:00
Dale Rahn
078fb4d38e Delete obsolete API functions. 2013-11-05 13:44:36 -05:00
Dale Rahn
96f7305c29 One DB instad of many.
improved error handling

Fix testing, no point in running tests multiple times

Fix error when no blocks in database, reopen would misreport NewstSha() return
2013-09-10 10:05:26 -04:00
Dale Rahn
b66abdf6ba Initial leveldb code.
This code is still prototype at this time.
It appears to function correctly but something
consumes more memory than is considered reasonable
for the dataset comprised of the full bitcoind chain.

Not recommened for use at this time.
2013-08-22 09:34:50 -04:00