[ https://issues.apache.org/jira/browse/HADOOP-1375?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12506702 ]
stack commented on HADOOP-1375: ------------------------------- Hey Jinsuk: I'd suggest you spend might spend more time testing before you upload new patches. It didn't take me long to find the below problems: If I type 'help;', at end of the usage screen it says: 'Unknown command: Type 'help' for usage'. Same if I do 'help show;'. Does the 'show' command only work with a 'tables' argument? Seems to fail for all else. If so, I'd suggest you make the help state that it only takes table arguments explicitly (Version 2 you can add other objects to the show list). If I try to scan the root table, it crashes the shell: {code} HBase > scan --ROOT-- --> ; Exception in thread "main" java.lang.Error: Missing return statement in function at org.apache.hadoop.hbase.shell.generated.Parser.parse(Parser.java:153) at org.apache.hadoop.hbase.shell.HBaseShell.main(HBaseShell.java:66) {code} I made a table named 'x' with a column family named 'one' by doing the following: "create x columnfamilies('one', 'two') limit=3;" I then tried to make use of it. Here I am trying to add a value but I have not specified a row (and I may be using the wrong quoting means): {code} HBase > set x values('one:' 'x'); Exception in thread "main" org.apache.hadoop.hbase.shell.generated.ParseException: Encountered "\'x\'" at line 1, column 22. Was expecting one of: "," ... ")" ... at org.apache.hadoop.hbase.shell.generated.Parser.generateParseException(Parser.java:441) at org.apache.hadoop.hbase.shell.generated.Parser.jj_consume_token(Parser.java:377) at org.apache.hadoop.hbase.shell.generated.Parser.getLiteralValues(Parser.java:174) at org.apache.hadoop.hbase.shell.generated.Parser.parse(Parser.java:127) at org.apache.hadoop.hbase.shell.HBaseShell.main(HBaseShell.java:66) {code} The shell should just complain about a missing parameter, not crash. Here I mistakenly add an equals after the row: {code} HBase > set x values("one:", "x") where row="y"; Exception in thread "main" org.apache.hadoop.hbase.shell.generated.ParseException: Encountered "\"one:\"" at line 1, column 15. Was expecting: <STRING_LITERAL> ... at org.apache.hadoop.hbase.shell.generated.Parser.generateParseException(Parser.java:441) at org.apache.hadoop.hbase.shell.generated.Parser.jj_consume_token(Parser.java:377) at org.apache.hadoop.hbase.shell.generated.Parser.getStringLiteral(Parser.java:182) at org.apache.hadoop.hbase.shell.generated.Parser.getLiteralValues(Parser.java:160) at org.apache.hadoop.hbase.shell.generated.Parser.parse(Parser.java:127) at org.apache.hadoop.hbase.shell.HBaseShell.main(HBaseShell.java:66) {code} Here is another: {code} HBase > set x values('one:', 'y'); Exception in thread "main" java.lang.NullPointerException at org.apache.hadoop.hbase.shell.Parameters.getRowKey(Parameters.java:38) at org.apache.hadoop.hbase.shell.cmds.Set.checkParams(Set.java:55) at org.apache.hadoop.hbase.shell.cmds.Set.execute(Set.java:33) at org.apache.hadoop.hbase.shell.HBaseShell.main(HBaseShell.java:68) {code} And here's a couple of comments on the wiki page: First, nice documentation. You should add a referral to this patch at the head of your page so people are not confused when they are unable to locate HBaseShell in the src (Because patch is not yet committed). Its a pity this page wasn't added under HBase but maybe we can get a wiki administrator to move it. I'd suggest that you save up all your edits and do one commit rather than lots of little updates. A diff of changes shows on the dev list. Lots of small changes makes for lots of mail (If you haven't already, check out the 'preview' button). You say "Hbase Shell is an 'interpreter' (or 'shell)' to provide scalable data processing capabilities like aggregation, algebraic calculation on Hadoop + Hbase." This seems wrong. HBaseShell will not be providing 'scalable data processing'. Nor, from 'goals' will it provide 'Generic Query Model Functions' or 'Parallel Numerical Analysis ...' These seems like facilities distinct from what HBaseShell does, providing a command-line means of admining and updating hbase as the 'mysql' comand-line tool does for mysql. I'd suggest you narrow the focus of this page and just describe HBaseShell, how to invoke it and examples of what you can do at the 'HBase >' prompt. Make another page for dicussion of the matrix features you propose adding to hbase (But perhaps wait on adding this page until you have a corresponding patch with at least a skeleton of the functionality you intend to add). > a simple parser for hbase. > -------------------------- > > Key: HADOOP-1375 > URL: https://issues.apache.org/jira/browse/HADOOP-1375 > Project: Hadoop > Issue Type: Improvement > Components: contrib/hbase > Environment: All environments > Reporter: udanax > Priority: Minor > Attachments: hadoop1375-v12.patch, jline-0.9.91.jar, patch.txt, > patch.txt, patch.txt, patch.txt, patch.txt, patch.txt, patch.txt, patch.txt, > patch.txt, patch.txt, patch.txt > > > http://wiki.apache.org/lucene-hadoop/HbaseShell (work in progress) > HBase Shell is developed to achieve the following goals. > * Generic Monitoring Function > * A Simplified Import/Export/Migrate Functionality Between different data > sources (Hadoop, HBase) > * A Simplified processing of a logical data model > * A Simplified algebraic operations > (Parallel Numerical Analysis by abstracting/numericalizing points, lines, > or plane data across multiple maps in HBase.) > {code} > [# [EMAIL PROTECTED] ./bin/hadoop jar ./build/hadoop-hbase > org.apache.hadoop.hbase.shell.HbaseShell > Hbase > help; > blah blah... > Hbase > create webtable > --> columnfamilies('anchors', 'language') limit=3; > Hbase > set webtable values('anchors:http://www.udanax.org/','opensource') > where row="http://www.hadoop.co.kr"; > Hbase > scan webtable where row="http://www.hadoop.co.kr"; > blah blah... > Hbase > set webtable values('language:kr','euc-kr') where > row="http://www.hadoop.co.kr"; > Hbase > scan webtable where row="http://www.hadoop.co.kr" and > column="language:kr"; > blah blah... > Hbase > scan webtable; > Hbase > exit > [# [EMAIL PROTECTED] > {code} -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.