Skip to content
This repository has been archived by the owner on Apr 8, 2019. It is now read-only.

build index for hbase #7

Closed
5 tasks done
at15 opened this issue Nov 29, 2015 · 6 comments
Closed
5 tasks done

build index for hbase #7

at15 opened this issue Nov 29, 2015 · 6 comments

Comments

@at15
Copy link
Owner

at15 commented Nov 29, 2015

for instance we have a htable like this

rowkey  info:name info:email
1            jack          jack@123.com
2            dick          dick@123.com

we need a table to index this table by info:name

rowkey row
dick       2
jack      1

use mapreduce to do this

  • setup hbase with existing hadoop
  • write fake data
  • write the mapper
  • see the result
  • send mail to TA
@at15
Copy link
Owner Author

at15 commented Nov 29, 2015

why I only knew this today .... e ....

@at15
Copy link
Owner Author

at15 commented Nov 29, 2015

@at15
Copy link
Owner Author

at15 commented Nov 29, 2015

Exception in thread "main" org.apache.hadoop.hbase.client.RetriesExhaustedWithDetailsException: Failed 1 action: contacts: 1 time, 
    at org.apache.hadoop.hbase.client.AsyncProcess$BatchErrors.makeException(AsyncProcess.java:228)
    at org.apache.hadoop.hbase.client.AsyncProcess$BatchErrors.access$1700(AsyncProcess.java:208)
    at org.apache.hadoop.hbase.client.AsyncProcess.waitForAllPreviousOpsAndReset(AsyncProcess.java:1689)
    at org.apache.hadoop.hbase.client.BufferedMutatorImpl.backgroundFlushCommits(BufferedMutatorImpl.java:208)
    at org.apache.hadoop.hbase.client.BufferedMutatorImpl.flush(BufferedMutatorImpl.java:183)
    at org.apache.hadoop.hbase.client.HTable.flushCommits(HTable.java:1449)
    at org.apache.hadoop.hbase.client.HTable.put(HTable.java:1040)
    at cn.edu.sjtu.stu.at15.hbase.Seeder.main(Seeder.java:33)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:144)

this is caused by

  • not creating table/column family

the class won't create the table automatically I guess ....

@at15
Copy link
Owner Author

at15 commented Nov 29, 2015

https://books.google.com/books?id=nUhiQxUXVpMC HBase: The Definitive Guide

@at15
Copy link
Owner Author

at15 commented Nov 29, 2015

@at15
Copy link
Owner Author

at15 commented Nov 29, 2015

finished in 60c1b83

@at15 at15 closed this as completed Nov 29, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant