Clarification on key filters

Jeremiah Peschka jeremiah.peschka at
Wed May 25 21:34:46 EDT 2011

An MR job has 0 or more key filters. Adding a few transforms generates a
lovely list of lists:

     "key_filters":[["tokenize", "-", 1],
                    ["matches", "solutions"]]
   // ...}

That makes sense: we've got a list of key filters. And a key filter is, in
effect, a list of arguments.

The complex predicates are throwing me off. Looking at the spec from Ripple
in filter_builder_spec.rb [1] and it's showing that

subject.OR do
  starts_with "foo"
  ends_with "bar"


[[:or, [[:starts_with, "foo"],[:ends_with, "bar"]]]]

Which is not at all the same as what the wiki says an OR should look like:

["or", [["eq", "google"]], [["less_than", "g"]]]

Apart from the obvious difference in syntax, have I been drinking mouthwash
or did the wiki suddenly switch from showing a complete key filter condition
to showing an individual key filter command for AND, OR, and NOT?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the riak-users mailing list