Skip to content

Commit 7520091

Browse files
author
Cary Huang
committed
documentation revisions
1 parent 059c132 commit 7520091

File tree

6 files changed

+37
-22
lines changed

6 files changed

+37
-22
lines changed

docs/en/user-guide/default_datatype_mapping.md

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ The default data type mapping entries can be overwritten by defining a object ma
1919
## **MySQL Default Data Type Mapping**
2020

2121
```c
22-
datatypehashentry mysql_defaulttypemappings[] =
22+
DatatypeHashEntry mysql_defaultTypeMappings[] =
2323
{
2424
{{"int", true}, "serial", 0},
2525
{{"bigint", true}, "bigserial", 0},
@@ -70,8 +70,6 @@ datatypehashentry mysql_defaulttypemappings[] =
7070
{{"mediumtext", false}, "text", -1},
7171
{{"tinytext", false}, "text", -1},
7272
{{"json", false}, "jsonb", -1},
73-
74-
/* spatial types - map to text by default */
7573
{{"geometry", false}, "text", -1},
7674
{{"geometrycollection", false}, "text", -1},
7775
{{"geomcollection", false}, "text", -1},
@@ -87,7 +85,7 @@ datatypehashentry mysql_defaulttypemappings[] =
8785
## **SQL Server Default Data Type Mapping**
8886

8987
```c
90-
datatypehashentry sqlserver_defaulttypemappings[] =
88+
DatatypeHashEntry sqlserver_defaultTypeMappings[] =
9189
{
9290
{{"int identity", true}, "serial", 0},
9391
{{"bigint identity", true}, "bigserial", 0},
@@ -97,8 +95,8 @@ datatypehashentry sqlserver_defaulttypemappings[] =
9795
{{"bigint", false}, "bigint", 0},
9896
{{"smallint", false}, "smallint", 0},
9997
{{"tinyint", false}, "smallint", 0},
100-
{{"numeric", false}, "numeric", 0},
101-
{{"decimal", false}, "numeric", 0},
98+
{{"numeric", false}, "numeric", -1},
99+
{{"decimal", false}, "numeric", -1},
102100
{{"bit(1)", false}, "bool", 0},
103101
{{"bit", false}, "bit", 0},
104102
{{"money", false}, "money", 0},
@@ -121,8 +119,10 @@ datatypehashentry sqlserver_defaulttypemappings[] =
121119
{{"varbinary", false}, "bytea", 0},
122120
{{"image", false}, "bytea", 0},
123121
{{"uniqueidentifier", false}, "uuid", 0},
124-
{{"xml", false}, "text", 0},
125-
/* spatial types - map to text by default */
122+
{{"xml", false}, "xml", 0},
123+
{{"json", false}, "jsonb", -1},
124+
{{"hierarchyid", false}, "text", 0},
125+
{{"vector", false}, "text", 0},
126126
{{"geometry", false}, "text", 0},
127127
{{"geography", false}, "text", 0},
128128
};
@@ -196,10 +196,16 @@ DatatypeHashEntry oracle_defaultTypeMappings[] =
196196
{{"rowid", false}, "text", 0},
197197
{{"urowid", false}, "text", 0},
198198
{{"xmltype", false}, "text", 0},
199-
/* large objects */
200199
{{"bfile", false}, "text", 0},
201200
{{"blob", false}, "bytea", 0},
202201
{{"clob", false}, "text", 0},
203-
{{"nclob", false}, "text", 0}
202+
{{"nclob", false}, "text", 0},
203+
{{"sdo_geometry", false}, "text", 0},
204+
{{"sdo_topo_geometry", false}, "text", 0},
205+
{{"sdo_georaster", false}, "text", 0},
206+
{{"uritype", false}, "text", 0},
207+
{{"anytype", false}, "text", 0},
208+
{{"anydata", false}, "text", 0},
209+
{{"anydataset", false}, "text", 0},
204210
};
205211
```

docs/en/user-guide/secured_connection.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
to secure the connection to remote database, we need to configure additional SSL related parameters to a connector that has been created by `synchdb_add_conninfo`. The SSL certificates and private keys must be packaged as Java keystore file with a passphrase. These information is then passed to SynchDB via synchdb_add_extra_conninfo().
66

7+
<<**IMPORTANT**>> Secured connection is not available for Openlog Replicator Connector
78

89
## **synchdb_add_extra_conninfo**
910

docs/en/user-guide/set_offset.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ postgres=# select name, last_dbz_offset from synchdb_state_view;
1515
---------------+------------------------------------------------------------------------------------------------------
1616
sqlserverconn | {"commit_lsn":"0000006a:00006608:0003","snapshot":true,"snapshot_completed":false}
1717
mysqlconn | {"ts_sec":1741301103,"file":"mysql-bin.000009","pos":574318212,"row":1,"server_id":223344,"event":2}
18-
oracleconn | offset file not flushed yet
18+
oracleconn | {"commit_scn":"2311579","snapshot_scn":"2311578","scn":"2311578"}
1919
(3 rows)
2020

2121
```

docs/zh/user-guide/default_datatype_mapping.md

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ weight: 50
1616

1717
## **MySQL 默认数据类型映射**
1818
```c
19-
datatypehashentry mysql_defaulttypemappings[] =
19+
DatatypeHashEntry mysql_defaultTypeMappings[] =
2020
{
2121
{{"int", true}, "serial", 0},
2222
{{"bigint", true}, "bigserial", 0},
@@ -67,8 +67,6 @@ datatypehashentry mysql_defaulttypemappings[] =
6767
{{"mediumtext", false}, "text", -1},
6868
{{"tinytext", false}, "text", -1},
6969
{{"json", false}, "jsonb", -1},
70-
71-
/* spatial types - map to text by default */
7270
{{"geometry", false}, "text", -1},
7371
{{"geometrycollection", false}, "text", -1},
7472
{{"geomcollection", false}, "text", -1},
@@ -84,7 +82,7 @@ datatypehashentry mysql_defaulttypemappings[] =
8482

8583
## **SQL Server 默认数据类型映射**
8684
```c
87-
datatypehashentry sqlserver_defaulttypemappings[] =
85+
DatatypeHashEntry sqlserver_defaultTypeMappings[] =
8886
{
8987
{{"int identity", true}, "serial", 0},
9088
{{"bigint identity", true}, "bigserial", 0},
@@ -94,8 +92,8 @@ datatypehashentry sqlserver_defaulttypemappings[] =
9492
{{"bigint", false}, "bigint", 0},
9593
{{"smallint", false}, "smallint", 0},
9694
{{"tinyint", false}, "smallint", 0},
97-
{{"numeric", false}, "numeric", 0},
98-
{{"decimal", false}, "numeric", 0},
95+
{{"numeric", false}, "numeric", -1},
96+
{{"decimal", false}, "numeric", -1},
9997
{{"bit(1)", false}, "bool", 0},
10098
{{"bit", false}, "bit", 0},
10199
{{"money", false}, "money", 0},
@@ -118,8 +116,10 @@ datatypehashentry sqlserver_defaulttypemappings[] =
118116
{{"varbinary", false}, "bytea", 0},
119117
{{"image", false}, "bytea", 0},
120118
{{"uniqueidentifier", false}, "uuid", 0},
121-
{{"xml", false}, "text", 0},
122-
/* spatial types - map to text by default */
119+
{{"xml", false}, "xml", 0},
120+
{{"json", false}, "jsonb", -1},
121+
{{"hierarchyid", false}, "text", 0},
122+
{{"vector", false}, "text", 0},
123123
{{"geometry", false}, "text", 0},
124124
{{"geography", false}, "text", 0},
125125
};
@@ -193,10 +193,16 @@ DatatypeHashEntry oracle_defaultTypeMappings[] =
193193
{{"rowid", false}, "text", 0},
194194
{{"urowid", false}, "text", 0},
195195
{{"xmltype", false}, "text", 0},
196-
/* large objects */
197196
{{"bfile", false}, "text", 0},
198197
{{"blob", false}, "bytea", 0},
199198
{{"clob", false}, "text", 0},
200-
{{"nclob", false}, "text", 0}
199+
{{"nclob", false}, "text", 0},
200+
{{"sdo_geometry", false}, "text", 0},
201+
{{"sdo_topo_geometry", false}, "text", 0},
202+
{{"sdo_georaster", false}, "text", 0},
203+
{{"uritype", false}, "text", 0},
204+
{{"anytype", false}, "text", 0},
205+
{{"anydata", false}, "text", 0},
206+
{{"anydataset", false}, "text", 0},
201207
};
202208
```

docs/zh/user-guide/secured_connection.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44

55
为了确保与远程数据库的连接安全,我们需要为 `synchdb_add_conninfo` 创建的连接器配置额外的 SSL 相关参数。SSL 证书和私钥必须打包为 Java 密钥库文件,并附带密码。这些信息随后会通过 synchdb_add_extra_conninfo() 传递给 SynchDB。
66

7+
<<**重要提示**>> Openlog Replicator 連接器不支援安全連接
8+
79
## **synchdb_add_extra_conninfo**
810

911
**用途**:为 `synchdb_add_conninfo` 创建的现有连接器配置额外的连接器参数

docs/zh/user-guide/set_offset.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ postgres=# select name, last_dbz_offset from synchdb_state_view;
1414
---------------+------------------------------------------------------------------------------------------------------
1515
sqlserverconn | {"commit_lsn":"0000006a:00006608:0003","snapshot":true,"snapshot_completed":false}
1616
mysqlconn | {"ts_sec":1741301103,"file":"mysql-bin.000009","pos":574318212,"row":1,"server_id":223344,"event":2}
17-
oracleconn | offset file not flushed yet
17+
oracleconn | {"commit_scn":"2311579","snapshot_scn":"2311578","scn":"2311578"}
1818
(3 rows)
1919
2020
```

0 commit comments

Comments
 (0)