File size: 524 Bytes
efc0c0a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
"""Picks DB vs Tabular executor based on the source_type of the IR's source.

This is the only place in the structured query path where the schema/tabular
distinction matters. Every step before this is source-type-agnostic.
"""

from ...catalog.models import Catalog
from ..ir.models import QueryIR
from .base import BaseExecutor


class ExecutorDispatcher:
    def __init__(self, catalog: Catalog) -> None:
        self._catalog = catalog

    def pick(self, ir: QueryIR) -> BaseExecutor:
        raise NotImplementedError