Don't throw stack trace for classes that aren't vertices
--------------------------------------------------------

                 Key: GIRAPH-138
                 URL: https://issues.apache.org/jira/browse/GIRAPH-138
             Project: Giraph
          Issue Type: Improvement
            Reporter: Jakob Homan


Currently if one passes in a class that isn't a vertex, we throw up a complete 
stack trace:
{noformat}[tardis giraph-0.1]$ bin/giraph lib/giraph-0.1.jar 
org.apache.giraph.benchmark.PageRankBenchmark -w 10 -if 
org.apache.giraph.benchmark.PseudoRandomVertexInputFormat
Exception in thread "main" java.lang.RuntimeException: class 
org.apache.giraph.benchmark.PageRankBenchmark not 
org.apache.giraph.graph.BasicVertex
        at org.apache.hadoop.conf.Configuration.setClass(Configuration.java:858)
        at org.apache.giraph.graph.GiraphJob.setVertexClass(GiraphJob.java:395)
        at org.apache.giraph.GiraphRunner.run(GiraphRunner.java:94)
        at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
        at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:79)
        at org.apache.giraph.GiraphRunner.main(GiraphRunner.java:132)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.hadoop.util.RunJar.main(RunJar.java:156){noformat}
This type of user error is routine and should be caught and result in a more 
descriptive error message.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to