Skip to content

Commit

Permalink
fix bugs when bulkload is not enabled on Postgresql
Browse files Browse the repository at this point in the history
Signed-off-by: Lei Wang <[email protected]>
  • Loading branch information
doudoubobo committed Jul 11, 2024
1 parent 62f2390 commit 657dc6d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
6 changes: 5 additions & 1 deletion charts/gart/templates/debezium/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,11 @@ data:
"snapshot.mode": "always",
{{- end }}
{{- else }}
"snapshot.mode": "never",
{{- if eq .Values.dataconfig.dbType "mysql" }}
"snapshot.mode": "schema_only",
{{- else }}
"snapshot.mode": "no_data",
{{- end }}
{{- end }}
"database.server.id": "1",
"include.schema.changes": "false",
Expand Down
2 changes: 1 addition & 1 deletion charts/gart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ debezium:
replicaCount: 1
image:
repository: debezium/connect
tag: latest
tag: 2.7.0.Final
pullPolicy: IfNotPresent
containerPort: 8083
resources: {}
Expand Down
2 changes: 0 additions & 2 deletions converter/parser.cc
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,6 @@ gart::Status TxnLogParser::parse(LogEntry& out, const string& log_str,
// default for PostgreSQL, -1 for MySQL
// TODO(SSJ): Hardcode for PostgreSQL and MySQL
int tx_id = log["source"].value("txId", -1);
/*
if (tx_id == -1) {
// MySQL
const json& gtid_json = log["source"]["gtid"];
Expand All @@ -314,7 +313,6 @@ gart::Status TxnLogParser::parse(LogEntry& out, const string& log_str,
LOG(ERROR) << "Please open GTID for MySQL.";
}
}
*/

out.tx_id = tx_id;

Expand Down
2 changes: 1 addition & 1 deletion scripts/install-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ database.user=<mysql user>
database.password=<mysql password>
database.include.list=<which databse is needed to capture, e.g., ldbc>
table.include.list=<list the tables in the order of vertices, then edges>
snapshot.mode=<if enable buldload, set as "initial", otherwise set as "never">
snapshot.mode=<if enable buldload, set as "initial", otherwise set as "schema_only">
$COMM_CONFIG
Expand Down

0 comments on commit 657dc6d

Please sign in to comment.