Examples of openTopLevel()


Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

        IndexKeyRange keyRange = IndexKeyRange.bounded(idxRowType, lo, true, hi, true);
        Operator plan = indexScan_Default(idxRowType, keyRange, ordering);
        long start = System.nanoTime();
        for (int r = 0; r < runs; r++) {
            Cursor cursor = cursor(plan, queryContext, queryBindings);
            cursor.openTopLevel();
            for (int s = 0; s < sequentialAccessesPerRandom; s++) {
                Row row = cursor.next();
                assert row != null;
            }
            cursor.close();
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

                if (key instanceof Integer) {
                    valueHolder.putInt64((long) ((Integer) key).intValue());
                } else {
                    valueHolder.putString((String) key, null);
                }
                cursor.openTopLevel();
                Row row = cursor.next();
                assert row != null;
                cursor.closeTopLevel();
            }
        }
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

        TimeOperator timeScan = new TimeOperator(scan);
        Operator select = select_HKeyOrdered(timeScan, tRowType, ExpressionGenerators.literal(Boolean.TRUE));
        long start = System.nanoTime();
        for (int r = 0; r < runs; r++) {
            Cursor cursor = cursor(select, queryContext, queryBindings);
            cursor.openTopLevel();
            while (cursor.next() != null);
        }
        long stop = System.nanoTime();
        long selectNsec = stop - start - timeScan.elapsedNsec();
        if (report) {
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

                StoreAdapter adapter = store().createAdapter(session(), schema);
                QueryContext context = new SimpleQueryContext(adapter, serviceManager());
                QueryBindings bindings = context.createBindings();
                List<Row> rows = new ArrayList<>();
                Cursor cursor = API.cursor(plan, context, bindings);
                cursor.openTopLevel();
                try {
                    Row row;
                    while((row = cursor.next()) != null) {
                        rows.add(row);
                    }
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

    protected List<Row> runPlanInternal(Session session, Schema schema, Operator plan) {
        StoreAdapter adapter = newStoreAdapter(session, schema);
        QueryContext context = queryContext(adapter);
        Cursor cursor = API.cursor(plan, context, context.createBindings());
        cursor.openTopLevel();
        try {
            List<Row> output = new ArrayList<>();
            Row row;
            while((row = cursor.next()) != null) {
                output.add(row);
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

        populateDB(CUSTOMERS, ORDERS_PER_CUSTOMER, ITEMS_PER_ORDER);
        long start = System.nanoTime();
        Operator plan = groupScan_Default(coi);
        for (int s = 0; s < SCANS; s++) {
            Cursor cursor = cursor(plan, queryContext, queryBindings);
            cursor.openTopLevel();
            while (cursor.next() != null) {
            }
            cursor.closeTopLevel();
        }
        long end = System.nanoTime();
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

        API.Ordering ordering = ordering(A, ASC, B, ASC, C, ASC, ID, ASC);
        long[] idOrdering = longs(1010, 1011, 1012, 1013, 1014, 1015);
        {
            Operator plan = indexScan_Default(idxRowType, bounded(1, 11, true, 13, true), ordering);
            Cursor cursor = cursor(plan, queryContext, queryBindings);
            cursor.openTopLevel();
            testJump(cursor, idOrdering, 0);
            testJump(cursor, idOrdering, -1);
            cursor.closeTopLevel();
        }
        {
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

            cursor.closeTopLevel();
        }
        {
            Operator plan = indexScan_Default(idxRowType, bounded(1, 11, true, 13, false), ordering);
            Cursor cursor = cursor(plan, queryContext, queryBindings);
            cursor.openTopLevel();
            testJump(cursor, first4(idOrdering), 0);
            testJump(cursor, first4(idOrdering), -1);
            cursor.closeTopLevel();
        }
        {
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

            cursor.closeTopLevel();
        }
        {
            Operator plan = indexScan_Default(idxRowType, bounded(1, 11, false, 13, true), ordering);
            Cursor cursor = cursor(plan, queryContext, queryBindings);
            cursor.openTopLevel();
            testJump(cursor, last4(idOrdering), 0);
            testJump(cursor, last4(idOrdering), -1);
            cursor.closeTopLevel();
        }
        {
View Full Code Here

Examples of com.foundationdb.qp.operator.Cursor.openTopLevel()

            cursor.closeTopLevel();
        }
        {
            Operator plan = indexScan_Default(idxRowType, bounded(1, 11, false, 13, false), ordering);
            Cursor cursor = cursor(plan, queryContext, queryBindings);
            cursor.openTopLevel();
            testJump(cursor, middle2(idOrdering), 0);
            testJump(cursor, middle2(idOrdering), -1);
            cursor.closeTopLevel();
        }
    }
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.