jiak interface trouble? missing objects?

Thomas Heller info at zilence.net
Wed Jan 27 11:00:27 EST 2010


Hi there,

I've recently started playing arround with riak but didnt get far
since jiak doesnt return any objects over http. Heres what I did:

hg clone http://hg.basho.com/riak/
cd riak
make rel
cd rel/riak
bin/riak console

Then I ran riak/client/lib/jiak.rb, which when done has created the
bucket 'foo' and a doc 'my known key'. When I look at that with jiak
via http directly:

http://127.0.0.1:8098/jiak/foo/my%20known%20key

{
    "object": {

    },
    "vclock": "a85hYGBgzmDKBVIsT8paEjKYEpnyWBk6Ll05wgcRZmtOYrqsrgOUYARKXLsBl2CZv+/MOqh6sHAWAA==",
    "lastmod": "Wed, 27 Jan 2010 15:33:42 GMT",
    "vtag": "kNMLaYYg3weS65I0EuRbO",
    "bucket": "foo",
    "key": "my known key",
    "links": [
        [
            "foo",
            "84UuyhE4fh68UDmKnQyJvc9LZy2",
            "tagged"
        ]
    ]
}

As you can see object:{} is empty, which obviously means an empty
object in ruby as well. But when I check with erlang (in the riak
console):

{ok, C} = riak:client_connect('riak at 127.0.0.1').
{ok, O} = C:get(<<"foo">>, <<"my known key">>, 1).
(riak at 127.0.0.1)4> riak_object:get_values(O).
[{{struct,[{<<"baz">>,<<"good">>},{<<"bar">>,42}]},
  [[<<"foo">>,<<"84UuyhE4fh68UDmKnQyJvc9LZy2">>,
    <<"tagged">>]]}]

There are the object values I'd expect { 'baz':'good', 'bar':42 }.

Am I missing something or is jiak just not done yet?

Thanks,
/thomas




More information about the riak-users mailing list