Open MeltyBot opened 3 years ago
On revisiting this issue, I found we already have handling available for targets and sinks in the SDK:
ACTIVATE_VERSION
in targets, the developer simply overrides Sink.activate_version(version_num: int)
.SQLSink
classes automatically get some handling.
hard_delete
being searched for but never declared or advertised in docs. We should add testing and/or a reference implementation in target-postgres or target-snowflake.FULL_TABLE
mode, Stream
should be modified with the following:version
integer (or perhaps full_table_version
for clarity) as an epoch form of the streams' signpost timestamp calculation.
ACTIVATE_VERSION
message.ACTIVATE_VERSION
message in our "Implementation Reference" section.I just closed #607 as stale. I did not have bandwidth at the time to get everything polished/tested. But future developers could definitely use this as a starting point.
What is the current state of ACTIVATE_VERSION message type for taps/targets?
Migrated from GitLab: https://gitlab.com/meltano/sdk/-/issues/18
Originally created by @aaronsteers on 2021-01-06 23:04:29
From the singer-python library:
Implementing for taps:
I think we can safely implement for taps and send the message by default. For cases where targets cannot tolerate the unknown message types, we should support a
disable_activate_version_messages=True
option.When
FULL_TABLE
replication is selected in the tap:version
as property within emittedRECORD
messages. https://github.com/transferwise/pipelinewise-tap-snowflake/blob/aa89f2e4235999dbeafc7406a7f8b382542d8d5b/tap_snowflake/sync_strategies/common.py#L200ACTIVATE_VERSION
at the beginning of the firstFULL_TABLE
sync operation: https://github.com/transferwise/pipelinewise-tap-snowflake/blob/aa89f2e4235999dbeafc7406a7f8b382542d8d5b/tap_snowflake/sync_strategies/full_table.py#L87-L95ACTIVATE_VERSION
after a successfulFULL_TABLE
sync: https://github.com/transferwise/pipelinewise-tap-snowflake/blob/aa89f2e4235999dbeafc7406a7f8b382542d8d5b/tap_snowflake/sync_strategies/full_table.py#L114