Package edu.brown.designer.partitioners.BranchAndBoundPartitioner

Examples of edu.brown.designer.partitioners.BranchAndBoundPartitioner.StateVertex


        hints.max_memory_per_partition = 1;
        hints.enable_procparameter_search = false;
        this.partitioner.setParameters(agraph, table_visit_order, proc_visit_order);
        this.partitioner.init(this.hints);
       
        StateVertex start_vertex = StateVertex.getStartVertex(Double.MAX_VALUE, Long.MAX_VALUE);
        TraverseThread thread = this.partitioner.new TraverseThread(info, hints, start_vertex, agraph, table_visit_order, proc_visit_order);
        assertNotNull(thread);
        thread.traverse(start_vertex, 0);
        this.partitioner.getHaltReason();
       
        // Make sure that the solution we pick has a memory and a cost
        StateVertex best_vertex = this.partitioner.getBestVertex();
        assertNotNull(best_vertex);
        assert(best_vertex.getCatalogKeyMap().isEmpty());
//        Map<CatalogType, CatalogType> m = best_vertex.getCatalogMap(catalog_db);
//        for (Table catalog_tbl : orig_partitioning.keySet()) {
//            assert(m.containsKey(catalog_tbl)) : "Missing " + catalog_tbl;
//            assertEquals(orig_partitioning.get(catalog_tbl).fullName(), m.get(catalog_tbl).fullName());
//        } // FOR
View Full Code Here


        hints.enable_procparameter_search = false;
        hints.max_memory_per_partition = Long.MAX_VALUE;
        this.partitioner.setParameters(agraph, table_visit_order, proc_visit_order);
        this.partitioner.init(this.hints);
       
        StateVertex start_vertex = StateVertex.getStartVertex(Double.MAX_VALUE, Long.MAX_VALUE);
        TraverseThread thread = this.partitioner.new TraverseThread(info, hints, start_vertex, agraph, table_visit_order, proc_visit_order);
        assertNotNull(thread);
        thread.traverse(start_vertex, 0);
       
        // Make sure that the solution we pick has a memory and a cost
        StateVertex best_vertex = this.partitioner.getBestVertex();
        assertNotNull(best_vertex);
        Map<CatalogType, CatalogType> m = best_vertex.getCatalogMap(catalog_db);
        for (Table t : expected.keySet()) {
            assert(m.containsKey(t)) : "Missing " + t;
            assertEquals(expected.get(t), m.get(t));
        } // FOR
        assert(best_vertex.getCost() > 0) : best_vertex.getCost();
        assert(best_vertex.getMemory() > 0) : best_vertex.getMemory();
    }
View Full Code Here

TOP

Related Classes of edu.brown.designer.partitioners.BranchAndBoundPartitioner.StateVertex

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.