Christian Decker
5912c68185
db: Add a hexval helper to decode hex values from db into fields
...
This is going to be handy pretty soon. Channels are almost fully
blobs...
2017-08-10 12:34:58 +09:30
Christian Decker
33ffb53d9e
db: Added schema for peers and channels
2017-08-10 12:34:58 +09:30
Christian Decker
416d6bf860
db: Enable foreign keys and cascade on shachain delete
...
Should make maintenance a bit easier.
2017-08-10 12:34:58 +09:30
Christian Decker
b0c64909e7
wallet: Added database schema for shachain persistence
2017-08-10 12:34:58 +09:30
Christian Decker
1522eee528
unittests: Test some more of the db primitives.
2017-06-23 16:02:20 +09:30
Christian Decker
257ecf6222
wallet: Helper to store/retrieve persistent vars to/from DB
...
Not the nicest code, but it allows us to store the bip32_max_index so
that we don't forget our addresses upon restart. We could have done
the same by retrieving the max index from our index, but then we'd
forget addresses that don't have an associated output. Conversion
to/from string is so that we can store arbitrary one off values in the
DB in the future, independent of type.
2017-06-06 09:16:10 +09:30
Christian Decker
19a4e7f542
wallet: Expose transactional interface for db
2017-06-06 09:16:10 +09:30
Christian Decker
9882a9fb29
wallet: Start the wallet interface and link it into lightningd
...
The database is hidden behind the wallet interface, which has all the
wallet specific functionality. First up is the tracking of outputs.
2017-06-06 09:16:10 +09:30
Christian Decker
80436d06cb
wallet: Create and manage a sqlite3 database for the wallet
2017-06-06 09:16:10 +09:30