Skip to content

Flink

Installation

pip install "toolfront[flink]"

Connection Parameters

Connect using the Database.from_flink() method with parameters:

1
2
3
4
5
6
7
8
9
from toolfront import Database
from pyflink.table import EnvironmentSettings, TableEnvironment

# Create PyFlink TableEnvironment
table_env = TableEnvironment.create(EnvironmentSettings.in_streaming_mode())

db = Database.from_flink(table_env=table_env)

revenue = db.ask("What's our total revenue this month?")
PARAMETER DESCRIPTION
table_env

PyFlink TableEnvironment instance.

TYPE: TableEnvironment

match_schema

Regex pattern to filter schemas. Mutually exclusive with match_tables.

TYPE: str DEFAULT: None

match_tables

Regex pattern to filter tables. Mutually exclusive with match_schema.

TYPE: str DEFAULT: None

**kwargs

Additional arguments passed to the DBAPI connection call.

TYPE: Any DEFAULT: {}