git-annex/Database
Joey Hess c35a9047d3
improve data types for sqlite
This is a non-backwards compatable change, so not suitable for merging
w/o a annex.version bump and transition code. Not yet tested.

This improves performance of git-annex benchmark --databases
across the board by 10-25%, since eg Key roundtrips as a ByteString.

(serializeKey' produces a lazy ByteString, so there is still a
copy involved in converting it to a strict ByteString. It may be faster
to switch to using bytestring-strict-builder.)

FilePath and Key are both stored as blobs. This avoids mojibake in some
situations. It would be possible to use varchar instead, if persistent
could avoid converting that to Text, but it seems there is no good
way to do so. See doc/todo/sqlite_database_improvements.mdwn

Eliminated some ugly artifacts of using Read/Show serialization;
constructors and quoted strings are no longer stored in sqlite.

Renamed SRef to SSha to reflect that it is only ever a git sha,
not a ref name. Since it is limited to the characters in a sha,
it is not affected by mojibake, so still uses String.
2019-10-29 17:05:36 -04:00
..
Keys improve data types for sqlite 2019-10-29 17:05:36 -04:00
Benchmark.hs improve data types for sqlite 2019-10-29 17:05:36 -04:00
ContentIdentifier.hs improve data types for sqlite 2019-10-29 17:05:36 -04:00
Export.hs improve data types for sqlite 2019-10-29 17:05:36 -04:00
Fsck.hs improve data types for sqlite 2019-10-29 17:05:36 -04:00
Handle.hs display sqlite error message when it crashes 2019-10-24 11:50:55 -04:00
Init.hs remove many old version ifdefs 2019-07-05 15:09:37 -04:00
Keys.hs improve data types for sqlite 2019-10-29 17:05:36 -04:00
Queue.hs update licenses from GPL to AGPL 2019-03-13 15:48:14 -04:00
Types.hs improve data types for sqlite 2019-10-29 17:05:36 -04:00