Skip to content


Subversion checkout URL

You can clone with
Download ZIP

Serving Layer

Michael Hausenblas edited this page · 2 revisions
Clone this wiki locally


Once the serving layer has been built you can execute any of the following queries. First, of course, you need to launch the HBase shell:

$ ./bin/hbase shell

Acquaintances by network

List people Ellen knows from Google+:

hbase(main):001:0> scan 'usn_friends', { COLUMNS => ['a:network'], FILTER => "ValueFilter(=,'substring:G')", STARTROW => 'Ellen', ENDROW => 'F' }
ROW                   COLUMN+CELL
 Ellen_2012-03-12     column=a:network, timestamp=1370630348302, value=G
 Ellen_2012-03-24     column=a:network, timestamp=1370630348294, value=G
 Ellen_2013-03-27     column=a:network, timestamp=1370630348297, value=G
15 row(s) in 0.0440 seconds

Acquaintances by time

List people Ted acquainted in or after January 2013 on LinkedIn:

hbase(main):001:0> scan 'usn_friends', { COLUMNS => ['a'], FILTER => "ValueFilter(=,'substring:L')", STARTROW => 'Ted_2013-01'}
ROW                                      COLUMN+CELL
 Ted_2013-01-17                          column=a:comment, timestamp=1370630348723, value=urna et arcu imperdiet ullamcorper. Duis at lacus. Quisque purus
 Ted_2013-03-25                          column=a:network, timestamp=1370630348769, value=L
8 row(s) in 0.0460 seconds

Something went wrong with that request. Please try again.