Package org.apache.giraph.graph

Examples of org.apache.giraph.graph.GraphMapper$OverrideExceptionHandler


    }

    public void testMatchingType() throws SecurityException,
            NoSuchMethodException, NoSuchFieldException {
        @SuppressWarnings("rawtypes")
        GraphMapper<?, ?, ?, ?> mapper = new GraphMapper();
        Configuration conf = new Configuration();
        conf.setClass(GiraphJob.VERTEX_CLASS,
                      GeneratedVertexMatch.class,
                      BasicVertex.class);
        conf.setClass(GiraphJob.VERTEX_INPUT_FORMAT_CLASS,
                      SimpleSuperstepVertexInputFormat.class,
                      VertexInputFormat.class);
        conf.setClass(GiraphJob.VERTEX_COMBINER_CLASS,
                      GeneratedVertexMatchCombiner.class,
                      VertexCombiner.class);
        mapper.determineClassTypes(conf);
    }
View Full Code Here


    }

    public void testDerivedMatchingType() throws SecurityException,
            NoSuchMethodException, NoSuchFieldException {
        @SuppressWarnings("rawtypes")
        GraphMapper<?, ?, ?, ?> mapper = new GraphMapper();
        Configuration conf = new Configuration();
        conf.setClass(GiraphJob.VERTEX_CLASS,
                      DerivedVertexMatch.class,
                      BasicVertex.class);
        conf.setClass(GiraphJob.VERTEX_INPUT_FORMAT_CLASS,
                      SimpleSuperstepVertexInputFormat.class,
                      VertexInputFormat.class);
        mapper.determineClassTypes(conf);
    }
View Full Code Here

    }

    public void testDerivedInputFormatType() throws SecurityException,
            NoSuchMethodException, NoSuchFieldException {
        @SuppressWarnings("rawtypes")
        GraphMapper<?, ?, ?, ?> mapper = new GraphMapper();
        Configuration conf = new Configuration();
        conf.setClass(GiraphJob.VERTEX_CLASS,
                      DerivedVertexMatch.class,
                      BasicVertex.class);
        conf.setClass(GiraphJob.VERTEX_INPUT_FORMAT_CLASS,
                      SimpleSuperstepVertexInputFormat.class,
                      VertexInputFormat.class);
        mapper.determineClassTypes(conf);
    }
View Full Code Here

    }

    public void testMismatchingVertex() throws SecurityException,
            NoSuchMethodException, NoSuchFieldException {
        @SuppressWarnings("rawtypes")
        GraphMapper<?, ?, ?, ?> mapper = new GraphMapper();
        Configuration conf = new Configuration();
        conf.setClass(GiraphJob.VERTEX_CLASS,
                      GeneratedVertexMismatch.class,
                      BasicVertex.class);
        conf.setClass(GiraphJob.VERTEX_INPUT_FORMAT_CLASS,
                      SimpleSuperstepVertexInputFormat.class,
                      VertexInputFormat.class);
        try {
            mapper.determineClassTypes(conf);
            throw new RuntimeException(
                "testMismatchingVertex: Should have caught an exception!");
        } catch (IllegalArgumentException e) {
        }
    }
View Full Code Here

    }

    public void testMismatchingCombiner() throws SecurityException,
            NoSuchMethodException, NoSuchFieldException {
        @SuppressWarnings("rawtypes")
        GraphMapper<?, ?, ?, ?> mapper = new GraphMapper();
        Configuration conf = new Configuration();
        conf.setClass(GiraphJob.VERTEX_CLASS,
                      GeneratedVertexMatch.class,
                      BasicVertex.class);
        conf.setClass(GiraphJob.VERTEX_INPUT_FORMAT_CLASS,
                      SimpleSuperstepVertexInputFormat.class,
                      VertexInputFormat.class);
        conf.setClass(GiraphJob.VERTEX_COMBINER_CLASS,
                      GeneratedVertexMismatchCombiner.class,
                      VertexCombiner.class);
        try {
            mapper.determineClassTypes(conf);
            throw new RuntimeException(
                "testMismatchingCombiner: Should have caught an exception!");
        } catch (IllegalArgumentException e) {
        }
    }
View Full Code Here

    }

    public void testJsonBase64FormatType() throws SecurityException,
            NoSuchMethodException, NoSuchFieldException {
        @SuppressWarnings("rawtypes")
        GraphMapper<?, ?, ?, ?> mapper = new GraphMapper();
        Configuration conf = new Configuration();
        conf.setClass(GiraphJob.VERTEX_CLASS,
                      GeneratedVertexMatch.class,
                      BasicVertex.class);
        conf.setClass(GiraphJob.VERTEX_INPUT_FORMAT_CLASS,
                      JsonBase64VertexInputFormat.class,
                      VertexInputFormat.class);
        conf.setClass(GiraphJob.VERTEX_OUTPUT_FORMAT_CLASS,
                      JsonBase64VertexOutputFormat.class,
                      VertexOutputFormat.class);
        mapper.determineClassTypes(conf);
    }
View Full Code Here

TOP

Related Classes of org.apache.giraph.graph.GraphMapper$OverrideExceptionHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.