Package com.facebook.presto.sql.planner

Examples of com.facebook.presto.sql.planner.LocalExecutionPlanner


        metadata.addInternalSchemaMetadata(dualMetadata);

        DualSplitManager dualSplitManager = new DualSplitManager(new InMemoryNodeManager());
        split = Iterables.getOnlyElement(dualSplitManager.getPartitionSplits(tableHandle, dualSplitManager.getPartitions(tableHandle, ImmutableMap.<ColumnHandle, Object>of())));

        planner = new LocalExecutionPlanner(
                new NodeInfo("test"),
                metadata,
                new DataStreamManager(new DualDataStreamProvider()),
                new MockLocalStorageManager(new File("target/temp")),
                new MockExchangeClientSupplier(),
View Full Code Here


        }

        SubPlan subplan = new DistributedLogicalPlanner(metadata, idAllocator).createSubplans(plan, true);
        assertTrue(subplan.getChildren().isEmpty(), "Expected subplan to have no children");

        LocalExecutionPlanner executionPlanner = new LocalExecutionPlanner(
                new NodeInfo(new NodeConfig()
                        .setEnvironment("test")
                        .setNodeId("test-node")),
                metadata,
                dataStreamProvider,
                storageManager,
                null,
                compiler);

        // plan query
        LocalExecutionPlan localExecutionPlan = executionPlanner.plan(session,
                subplan.getFragment().getRoot(),
                plan.getTypes(),
                outputFactory);

        // generate sources
View Full Code Here

    {
        MetadataManager metadata = new MetadataManager();

        PageSourceManager pageSourceManager = new PageSourceManager(new SystemRecordSetProvider());
        pageSourceManager.addConnectorPageSourceProvider("test", new TestingPageSourceProvider());
        return new LocalExecutionPlanner(
                metadata,
                new SqlParser(),
                pageSourceManager,
                new IndexManager(),
                new RecordSinkManager(),
View Full Code Here

        taskExecutor = new TaskExecutor(8);
        taskExecutor.start();

        taskNotificationExecutor = newScheduledThreadPool(5, threadsNamed("task-notification-%d"));

        LocalExecutionPlanner planner = createTestingPlanner();

        sqlTaskExecutionFactory = new SqlTaskExecutionFactory(
                taskNotificationExecutor,
                taskExecutor,
                planner,
View Full Code Here

        SubPlan subplan = new DistributedLogicalPlanner(session, metadata, idAllocator).createSubPlans(plan, true);
        if (!subplan.getChildren().isEmpty()) {
            throw new AssertionError("Expected subplan to have no children");
        }

        LocalExecutionPlanner executionPlanner = new LocalExecutionPlanner(
                new NodeInfo(new NodeConfig()
                        .setEnvironment("test")
                        .setNodeId("test-node")),
                metadata,
                dataStreamProvider,
                indexManager,
                recordSinkManager,
                null,
                compiler,
                new CompilerConfig().setInterpreterEnabled(false) // make sure tests fail if compiler breaks
        );

        // plan query
        LocalExecutionPlan localExecutionPlan = executionPlanner.plan(session,
                subplan.getFragment().getRoot(),
                plan.getTypes(),
                outputFactory);

        // generate sources
View Full Code Here

        SubPlan subplan = new DistributedLogicalPlanner(session, metadata, idAllocator).createSubPlans(plan, true);
        if (!subplan.getChildren().isEmpty()) {
            throw new AssertionError("Expected subplan to have no children");
        }

        LocalExecutionPlanner executionPlanner = new LocalExecutionPlanner(
                metadata,
                sqlParser,
                dataStreamProvider,
                indexManager,
                recordSinkManager,
                null,
                compiler,
                new CompilerConfig().setInterpreterEnabled(false) // make sure tests fail if compiler breaks
        );

        // plan query
        LocalExecutionPlan localExecutionPlan = executionPlanner.plan(session,
                subplan.getFragment().getRoot(),
                plan.getTypes(),
                outputFactory);

        // generate sources
View Full Code Here

        assertTrue(splitSource.isFinished());

        DataStreamManager dataStreamProvider = new DataStreamManager();
        dataStreamProvider.addConnectorDataStreamProvider(DualConnector.CONNECTOR_ID, new DualDataStreamProvider());

        LocalExecutionPlanner planner = new LocalExecutionPlanner(
                new NodeInfo("test"),
                metadata,
                dataStreamProvider,
                new IndexManager(),
                new MockLocalStorageManager(new File("target/temp")),
View Full Code Here

        MetadataManager metadata = new MetadataManager(new FeaturesConfig(), new TypeRegistry());

        DataStreamManager dataStreamProvider = new DataStreamManager();
        dataStreamProvider.addConnectorDataStreamProvider("test", new TestingDataStreamProvider());
        planner = new LocalExecutionPlanner(
                new NodeInfo("test"),
                metadata,
                dataStreamProvider,
                new IndexManager(),
                new RecordSinkManager(),
View Full Code Here

    {
        Symbol symbol = new Symbol("column");

        MetadataManager metadata = new MetadataManager(new FeaturesConfig(), new TypeRegistry());

        LocalExecutionPlanner planner = new LocalExecutionPlanner(
                new NodeInfo("test"),
                metadata,
                new DataStreamManager(),
                new IndexManager(),
                new RecordSinkManager(),
View Full Code Here

        SubPlan subplan = new DistributedLogicalPlanner(session, metadata, idAllocator).createSubPlans(plan, true);
        if (!subplan.getChildren().isEmpty()) {
            throw new AssertionError("Expected subplan to have no children");
        }

        LocalExecutionPlanner executionPlanner = new LocalExecutionPlanner(
                new NodeInfo(new NodeConfig()
                        .setEnvironment("test")
                        .setNodeId("test-node")),
                metadata,
                dataStreamProvider,
                indexManager,
                recordSinkManager,
                null,
                compiler);

        // plan query
        LocalExecutionPlan localExecutionPlan = executionPlanner.plan(session,
                subplan.getFragment().getRoot(),
                plan.getTypes(),
                outputFactory);

        // generate sources
View Full Code Here

TOP

Related Classes of com.facebook.presto.sql.planner.LocalExecutionPlanner

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.