Boost logo

Boost :

Subject: Re: [boost] [AFIO] Review (or lack of it)
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2015-08-30 10:48:18


On 29 Aug 2015 at 9:18, Robert Ramey wrote:

> > And, just to show you that your claim about unfounded claims is
> > unfounded (come on, seriously!), here is what the simplest API of an
> > STL-based named Blob store could look like IMO.
> >
> > #include <vector>
> > #include <string>
> >
> > class data_store
> > {
> > std::string _store_path;
> >
> > public:
> > data_store(std::string store_path);
> >
> > auto read(std::string name) const
> > -> std::vector<uint8_t>;
> >
> > auto write(std::string name, const std::vector<uint8_t>& blob)
> > -> void;
> > };
> >
> >
> > Please note that this one actually /is/ STL based.
>
> I've been looking at the comments in the review threads. Sometime ago I
> reviewed the documentation for the AFIO library. I sat in on two
> presentations on the subject at C++Now. That is all I know about the
> library. Sadly, I won't have time to make a review.
>
> The above comment is the only thing in all of this which has made any
> sense at all to me. I don't see why something like the above shouldn't
> be possible and I don't see why it would be a bad idea. A library which
> did this would be highly useful.

A transactional key-value store *is* coming. That's my end goal in
this: a standardised transactional key-value store built into the C++
language with bindings for C, Python, .NET and so on. I'm currently
hoping to bring that for Boost review start of 2017 (anyone who wants
to bring it to Boost by next spring instead can sponsor me for a very
reasonable hourly rate, drop me a line if you're interested).

I did a bit of mocking up of what the refactored data_store interface
for that AFIO tutorial will look like:

https://gist.github.com/ned14/163ac57c937bda61e5c9

Ok, so it's no longer the world's simplest key-value store API and I
deliberately dropped the STL iostreams interop, but the big
difference is that this one is real-world ready and probably quite
close to a final API design for such a thing.

Niall

-- 
ned Productions Limited Consulting
http://www.nedproductions.biz/ 
http://ie.linkedin.com/in/nialldouglas/



Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk