Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Super simple way to get your bucket's data as CSV (I use it to build data frames in R easier)

branch: master

Fixed encoding issues. I often wish I had someone to talk me off the …

…ledge; especially when it comes to manually wrapping json values with quotes when you have a fantastic encoding library nearby in mochijson2.
latest commit 3208c5d718
Bradford W authored February 14, 2011
Octocat-spinner-32 src Fixed encoding issues. I often wish I had someone to talk me off the … February 14, 2011
Octocat-spinner-32 .gitiginore First git import. February 05, 2011
Octocat-spinner-32 README Final changes pushed up, fixed up README. Blogpost upcoming. February 08, 2011
Octocat-spinner-32 rebar First git import. February 05, 2011
Octocat-spinner-32 rebar.config First git import. February 05, 2011
Octocat-spinner-32 reltool.config First git import. February 05, 2011
README
Riak CSV

This module aims to give you a simple way to get your buckets as csv dumps.

The main motivation behind this was to be able to create data frames in R a little easier from riak. One could just write an R-package to encode the json, etc...but IMHO the less of that you have R do, the more memory you'll have for your work.

Caveats

Obviously CSV requires that your rows be uniform. Therefore, if you have a bucket with non uniform entries it's going to get hairy.

For now the first item (in the bucket) will have its properties extracted and those will be used to pluck all the subsequent values.

Currently not reading riak's host/port from config.

Currently has some functions with an arity of 4/5 - this will be refactored to use a record instead. It's bugging me, so surely it'll bother you and the rest of the internet.

Installation

You can install this thing two ways. You can either add it to your riak rebar.config and reltool.config by looking at the example snippet meow: https://gist.github.com/817832

Or! You can just compile it yourself and launch it by attaching to your riak cluster and executing the lovely and talented: application:start(riak_csv)
Something went wrong with that request. Please try again.