reiddraper/sumo — pull request #6 by ifesdjeen (2011-12-25 22:10:09+00:00)
Title: Minor changes, trying to improve readability and ease of use

Thanks for the official Basho client! That was a great Christmas present for community! Hope to make it even more functional during next several weeks and use it in one of our prototype projects.

As far as I understand, get and put are more or less interface methods.

If there is a well-known list of options and it's unlikely to change, it may actually be good to specify that set to ease the future use, so

(client/get c bucket key { :head true })

will become:

(client/get c bucket key :head true)

moreover, it won't be possible to specify incorrect keys (if they make no sense, it's great to know about it during compile-time, right?)

Also I separated get-as-integer, fetch-options, store-options and delete-options to utils. I am not sure if you would like to have that change. I will add a test for each of those, and drop a couple of lines of doc. Even if these are private / helper methods, it's still good to have them clearly distinguishable for lib developers.

In the same manner, riak-object-to-map and map-to-riak-object are now in sumo.conversions. Although it feels that it's possible and/or better to re-do them as protocols. I'll try to do tomorrow or later next week.

Thanks again!