Uploaded image for project: 'Giraph (Retired)'
  1. Giraph (Retired)
  2. GIRAPH-529

Compile error when compiling the giraph shortest path problem: getOutEdgeMap()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Duplicate
    • None
    • None
    • None
    • None
    • Fedora 18(64-bit), hadoop-1.0.4 version, giraph-0.1.0 version

    Description

      I have some problem when I compiling the giraph shortest path problem

      I can't understand exactly getOutEdgeMap() method.
      Should I implement it?

      and also I have other compile errors.

      I just write a source code like this; https://github.com/aching/Giraph/wiki/Shortest-Paths-Example

      I attach error messages.

      --------------------
      sp/SimpleShortestPathVertex.java:55: error: cannot find symbol
      for(Edge<LongWritable, FloatWritable> edge : getOutEdgeMap().values()){
      ^
      symbol: method getOutEdgeMap()
      location: class SimpleShortestPathVertex
      sp/SimpleShortestPathVertex.java:74: error: cannot find symbol
      FileInputFormat.addInputPath(job, new Path(args[0]));
      ^
      symbol: variable FileInputFormat
      location: class SimpleShortestPathVertex
      sp/SimpleShortestPathVertex.java:75: error: cannot find symbol
      FileOutputFormat.setOutputPath(job, new Path(args[1]));
      ^
      symbol: variable FileOutputFormat
      location: class SimpleShortestPathVertex
      sp/SimpleShortestPathVertex.java:88: error: no suitable method found for run(SimpleShortestPathVertex,String[])
      System.exit(ToolRunner.run(new SimpleShortestPathVertex(), args));
      ^
      method ToolRunner.run(Tool,String[]) is not applicable
      (actual argument SimpleShortestPathVertex cannot be converted to Tool by method invocation conversion)
      method ToolRunner.run(Configuration,Tool,String[]) is not applicable
      (actual and formal argument lists differ in length)
      sp/SimpleShortestPathVertex.java:100: error: SimpleShortestPathVertexReader is not abstract and does not override abstract method getCurrentVertex() in VertexReader
      class SimpleShortestPathVertexReader extends TextVertexReader<LongWritable, DoubleWritable, FloatWritable, DoubleWritable>{
      ^
      sp/SimpleShortestPathVertex.java:121: error: method addEdge in class MutableVertex<I,V,E,M> cannot be applied to given types;
      vertex.addEdge(new Edge<LongWritable, FloatWritable>(new LongWritable(jEdge.getLong(0)), new FloatWritable((float)jEdge.getDouble(1))));
      ^
      required: LongWritable,FloatWritable
      found: Edge<LongWritable,FloatWritable>
      reason: actual and formal argument lists differ in length
      where I,V,E,M are type-variables:
      I extends WritableComparable declared in class MutableVertex
      V extends Writable declared in class MutableVertex
      E extends Writable declared in class MutableVertex
      M extends Writable declared in class MutableVertex
      sp/SimpleShortestPathVertex.java:139: error: lineRecordWriter has private access in TextVertexWriter
      super(lineRecordWriter);
      ^
      sp/SimpleShortestPathVertex.java:150: error: cannot find symbol
      for(Edge<LongWritable, FloatWritable> edge : vertex.getOutEdgeMap().values()){
      ^
      symbol: method getOutEdgeMap()
      location: variable vertex of type BasicVertex<LongWritable,DoubleWritable,FloatWritable,?>
      8 errors

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ilianes eunjihwang
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: