This is an archive of the discontinued Mercurial Phabricator instance.

simplestorerepo: minimal changes required to get this mostly working again
ClosedPublic

Authored by durin42 on Jan 7 2019, 6:49 PM.

Details

Summary

I was going to change this code's use of CBOR to use our in-house CBOR code,
but discovered it's been broken for a while. This messy change gets it back to
a point where it mostly works, I think roughly as well as it ever did.

Should we keep this and fix it up the rest of the way, or dump it in favor of
the sqlite store? Would this be a good jumping-off point for some sort of
union store that could facilitate a cleanup in remotefilelog?

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

durin42 created this revision.Jan 7 2019, 6:49 PM

The original purpose of the simple store repo was to flush out problems with storage abstraction by building an alternate storage backend. Now that we have storage interface unit tests and the SQLite storage backend, there is definitely less of a need for the simple store backend and we could probably consider deleting it.

The original purpose of the simple store repo was to flush out problems with storage abstraction by building an alternate storage backend. Now that we have storage interface unit tests and the SQLite storage backend, there is definitely less of a need for the simple store backend and we could probably consider deleting it.

I wonder if it's worth keeping the simpler simplestore code as an example. Probably not?

This revision was automatically updated to reflect the committed changes.

The original purpose of the simple store repo was to flush out problems with storage abstraction by building an alternate storage backend. Now that we have storage interface unit tests and the SQLite storage backend, there is definitely less of a need for the simple store backend and we could probably consider deleting it.

I wonder if it's worth keeping the simpler simplestore code as an example. Probably not?

With the SQLite store being a thing, probably not worth keeping even as an example. That being said, if it works and isn't hard to maintain, then why not keep it? The problem is it is difficult to maintain. You need to teach various tests about the existing of different backends because test output varies. Search for simplestore in the tests directory to see all the conditionals. Given the cost of maintaining support, I don't think it can justify its existence.

That being said, I'll probably regret this decision someday. Meh.