(In reply to Nan Jiang [:nanj] from comment #1)
NB: extra care should be taken when writing a large dataset in a single transaction. LMDB might return MDB_TXN_FULL errors from
I guess the fix for bug 1538372 could also run into this issue when migrating revocations.txt.
- Always check and handle errors from
store.put() and its variants
We're doing this for cert_storage, but only by propagating the error to the caller. In the case of cert_storage that will be some consumer of the nsICertStorage XPCOM API.
- If we still run into MDB_TXN_FULL errors, we can split the write into multiple sub-writes with multiple transactions. The downside is that it requires some extra bookkeeping, and could be hard to maintain the all-or-nothing support in certain cases.
Perhaps it would be possible to commit the transaction at that point and then create a new one?