Skip to content

Commit

Permalink
DBZ-8459 Add transforms and predicates into example
Browse files Browse the repository at this point in the history
Signed-off-by: Fiore Mario Vitale <[email protected]>
  • Loading branch information
mfvitale committed Jan 29, 2025
1 parent 83fcb04 commit 6c7a97b
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,9 @@ quarkus:
quarkus:
debezium-outbox:
remove-after-insert: false
hibernate-orm:
database:
generation: drop-and-create
flyway:
baseline-on-migrate: true
migrate-at-start: true
datasource:
devservices:
enabled: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ create table transform (
schema varchar(255) not null,
type varchar(255) not null,
config jsonb,
predicate_type VARCHAR(255),
predicate_config JSONB,
predicate_negate BOOLEAN,
primary key (id)
);

Expand Down

This file was deleted.

6 changes: 6 additions & 0 deletions examples/payloads/pipeline.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,11 @@
"id": 1,
"name": "test-destination"
},
"transforms": [
{
"name": "ExtractRecords",
"id": 1
}
],
"logLevel": "debug"
}
19 changes: 19 additions & 0 deletions examples/payloads/transform.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"name": "Debezium marker",
"description": "Extract Debezium payload",
"type": "io.debezium.transforms.ExtractNewRecordState",
"schema": "string",
"vaults": [
],
"config": {
"add.fields": "op",
"add.headers": "db,table"
},
"predicate": {
"type": "org.apache.kafka.connect.transforms.predicates.TopicNameMatches",
"config": {
"pattern": "inventory.inventory.products"
},
"negate": false
}
}
1 change: 1 addition & 0 deletions examples/seed.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ port=${2:-8080}
payloads_dir=${3:-payloads}
http POST ${url}:${port}/api/sources @${payloads_dir}/source.json
http POST ${url}:${port}/api/destinations @${payloads_dir}/destination.json
http POST ${url}:${port}/api/transforms @${payloads_dir}/transform.json
http POST ${url}:${port}/api/pipelines @${payloads_dir}/pipeline.json

0 comments on commit 6c7a97b

Please sign in to comment.