misc.python.materialize.zippy.pg_cdc_capabilities
1# Copyright Materialize, Inc. and contributors. All rights reserved. 2# 3# Use of this software is governed by the Business Source License 4# included in the LICENSE file at the root of this repository. 5# 6# As of the Change Date specified in that file, in accordance with 7# the Business Source License, use of this software will be governed 8# by the Apache License, Version 2.0. 9 10 11from materialize.zippy.postgres_capabilities import PostgresTableExists 12from materialize.zippy.watermarked_object_capabilities import WatermarkedObjectExists 13from materialize.zippy.watermarks import Watermarks 14 15 16class PostgresCdcTableExists(WatermarkedObjectExists): 17 """A Postgres CDC table exists in Materialize.""" 18 19 def __init__( 20 self, name: str, postgres_table: PostgresTableExists | None = None 21 ) -> None: 22 self.name = name 23 self.postgres_table = postgres_table 24 25 def get_watermarks(self) -> Watermarks: 26 assert self.postgres_table is not None 27 return self.postgres_table.watermarks 28 29 def get_name_for_query(self) -> str: 30 return self.name
class
PostgresCdcTableExists(materialize.zippy.watermarked_object_capabilities.WatermarkedObjectExists):
17class PostgresCdcTableExists(WatermarkedObjectExists): 18 """A Postgres CDC table exists in Materialize.""" 19 20 def __init__( 21 self, name: str, postgres_table: PostgresTableExists | None = None 22 ) -> None: 23 self.name = name 24 self.postgres_table = postgres_table 25 26 def get_watermarks(self) -> Watermarks: 27 assert self.postgres_table is not None 28 return self.postgres_table.watermarks 29 30 def get_name_for_query(self) -> str: 31 return self.name
A Postgres CDC table exists in Materialize.
PostgresCdcTableExists( name: str, postgres_table: materialize.zippy.postgres_capabilities.PostgresTableExists | None = None)