Module core.datasources.postgres_datasource

Postgres Datasource definition

Classes

PostgresDatasource(name: str, username: str, password: str, database: str, table: str, host: str = 'localhost', port: int = 5432, query_limit: int = None, schema: Dict = None, **kwargs) : ZenML Postgres datasource definition.

Use this for pipelines sourcing directly from a Postgres database table.

Initialize Postgres source. This creates a DataPipeline that
essentially performs the following query using Apache Beam.

`SELECT * FROM dataset.table LIMIT query_limit`
Args:
    name: Name of datasource.
    username: Username of database user.
    password: Password to connect to database.
    database: Name of the target database.
    table: Name of the target table.
    host: Host of database.
    port: Port to connect to with database (default 5432)
    query_limit: Max number of rows to fetch.
    schema: Dict specifying schema.

### Ancestors (in MRO)

* zenml.core.datasources.base_datasource.BaseDatasource

### Methods

`get_data_step(self)`
: