Package org.voltdb

Examples of org.voltdb.VoltTable.addRow()


                } // FOR
            } // FOR
           
            vt = new VoltTable(cols);
            for (Object[] row : totalRows.values()) {
                vt.addRow(row);
            } // FOR
        }
       
        // Write out CSV
        FileWriter out = new FileWriter(outputPath);
View Full Code Here


    public String formatFinalResults(BenchmarkResults br) {
        if (this.stop) return (null);
       
        VoltTable vt = new VoltTable(this.columns);
        for (Object row[] : this.results) {
            vt.addRow(row);
        }
       
        try {
            FileWriter writer = new FileWriter(this.outputPath);
            VoltTableUtil.csv(writer, vt, true);
View Full Code Here

                e.resultSize,
                e.clusterRoundTrip,
                e.clientRoundTrip,
                e.restartCounter,
            };
            vt.addRow(row);
        } // FOR
        return (vt);
    }
   
    // ----------------------------------------------------------------------------
View Full Code Here

    public String formatFinalResults(BenchmarkResults br) {
        if (this.stop) return (null);
       
        VoltTable vt = new VoltTable(COLUMNS);
        for (Object row[] : this.results) {
            vt.addRow(row);
        }
       
        try {
            FileWriter writer = new FileWriter(this.outputPath);
            VoltTableUtil.csv(writer, vt, true);
View Full Code Here

        // Load in some test data so the txn doesn't abort
        for (Table tbl : catalogContext.database.getTables()) {
            VoltTable vt = CatalogUtil.getVoltTable(tbl);
            Object row[] = VoltTableUtil.getRandomRow(tbl);
            row[0] = remotePartition;
            vt.addRow(row);
            this.remoteExecutor.loadTable(100l, tbl, vt, false);
        } // FOR
       
        AbstractConflictChecker remoteChecker = new AbstractConflictChecker(catalogContext) {
            @Override
View Full Code Here

        assertTrue(latch.getCount() > 0);
        WorkFragment.Builder fragment = CollectionUtil.first(ftasks);
        Collection<Column> outputCols = PlanNodeUtil.getOutputColumnsForStatement(nextBatch[0].getStatement());
        VoltTable result = CatalogUtil.getVoltTable(outputCols);
        result.addRow(VoltTableUtil.getRandomRow(result));
        this.depTracker.addResult(this.ts,
                                  fragment.getPartitionId(),
                                  fragment.getOutputDepId(0),
                                  result);
        assertEquals(0, latch.getCount());
View Full Code Here

        CountDownLatch latch = this.depTracker.getDependencyLatch(this.ts);
        assertEquals(nextBatch.length, latch.getCount());
        WorkFragment.Builder fragment = CollectionUtil.first(ftasks);
        Collection<Column> outputCols = PlanNodeUtil.getOutputColumnsForStatement(nextBatch[0].getStatement());
        VoltTable result = CatalogUtil.getVoltTable(outputCols);
        result.addRow(VoltTableUtil.getRandomRow(result));
        this.depTracker.addResult(this.ts,
                                  fragment.getPartitionId(),
                                  fragment.getOutputDepId(0),
                                  result);
        assertEquals(nextBatch.length-1, latch.getCount());
View Full Code Here

        for (int i = 0; i < num_rows; i++) {
            Object row[] = new Object[num_cols];
            for (int j = 0; j < num_cols; j++) {
                row[j] = VoltTypeUtil.getRandomValue(vt.getColumnType(j));
            } // FOR
            vt.addRow(row);
        } // FOR
        assertEquals(num_rows, vt.getRowCount());
       
        assertFalse(xact.hasOutput());
        xact.setOutput(vt);
View Full Code Here

                        eh.stopTimestamp,
                        eh.tuplesEvicted,
                        eh.blocksEvicted,
                        eh.bytesEvicted,
                    };
                    vt.addRow(row);
                } // FOR
                result = new DependencySet(DISTRIBUTE_ID, vt);
                if (debug.val)
                    LOG.info(String.format("%s - Sending back result for partition %d",
                             hstore_site.getTransaction(txn_id), this.executor.getPartitionId()));
View Full Code Here

                            procName,
                            eah.numBlocks,
                            eah.numTables,
                            eah.numTuples,
                        };
                        vt.addRow(row);
                } // FOR
                result = new DependencySet(DISTRIBUTE_ID, vt);
                if (debug.val)
                    LOG.info(String.format("%s - Sending back result for partition %d",
                             hstore_site.getTransaction(txn_id), this.executor.getPartitionId()));
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.