Skip to content

Commit

Permalink
add peerdb columns to ui, fix for bq cdc
Browse files Browse the repository at this point in the history
  • Loading branch information
Amogh-Bharadwaj committed Apr 29, 2024
1 parent 63bf892 commit 681979c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 3 deletions.
7 changes: 4 additions & 3 deletions flow/connectors/bigquery/bigquery.go
Original file line number Diff line number Diff line change
Expand Up @@ -639,9 +639,10 @@ func (c *BigQueryConnector) SetupNormalizedTable(

if softDeleteColName != "" {
columns = append(columns, &bigquery.FieldSchema{
Name: softDeleteColName,
Type: bigquery.BooleanFieldType,
Repeated: false,
Name: softDeleteColName,
Type: bigquery.BooleanFieldType,
Repeated: false,
DefaultValueExpression: "false",
})
}

Expand Down
20 changes: 20 additions & 0 deletions ui/app/mirrors/create/helpers/cdc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,4 +162,24 @@ export const cdcSettings: MirrorSetting[] = [
tips: 'Decide if PeerDB should use native Postgres types directly',
advanced: true,
},
{
label: 'Synced-At Column Name',
stateHandler: (value, setter) =>
setter((curr: CDCConfig) => ({
...curr,
syncedAtColName: value as string | '',
})),
tips: 'A field to set the name of PeerDBs synced_at column. If not set, a default name will be set',
advanced: true,
},
{
label: 'Soft Delete Column Name',
stateHandler: (value, setter) =>
setter((curr: CDCConfig) => ({
...curr,
softDeleteColName: value as string | '',
})),
tips: 'A field to set the name of PeerDBs soft delete column.',
advanced: true,
},
];

0 comments on commit 681979c

Please sign in to comment.