A very simple solution would be PStore from Ruby's Standard Library. It should meet almost all your requirements:
- PStore stores Ruby object hierarchies in files, so you can easily use the Hash-like structures, you would have in CouchDB
- You can access the contents of the PStore with a simple API
- It has transactions, but no versions as far as I know
- yes
- You can use Ruby's map and inject functions
- All you need is access to the file system
Example:
Insert data into the store:
require 'pstore'
store = PStore.new("/tmp/store")
store.transaction do
store["products"] = [{:name => "Test", :price => 100}
{:name => "Bla", :price => 120}
{:name => "Oink", :price => 300}]
end
Query the sum of the prices of all products:
store.transaction do
store['products'].map {|p| p[:price]}.inject {|sum, p| sum + p}
end
More information in this blog-post