From a947293b1d16a91f1bde134f186551a5e68e48dc Mon Sep 17 00:00:00 2001 From: He Wang Date: Thu, 24 Mar 2022 11:57:27 +0800 Subject: [PATCH] update logproxy-client tutorial with liboblog config (#32) --- docs/quickstart/logproxy-client-tutorial.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/quickstart/logproxy-client-tutorial.md b/docs/quickstart/logproxy-client-tutorial.md index 7cc5434..248f5e2 100644 --- a/docs/quickstart/logproxy-client-tutorial.md +++ b/docs/quickstart/logproxy-client-tutorial.md @@ -63,7 +63,9 @@ To connect to LogProxy, there are some parameters to set in `ObReaderConfig`: - *cluster_username*: Username for OceanBase, the format is `username@tenant_name#cluster_name` when connecting to [obproxy](https://github.com/oceanbase/obproxy) or `username@tenant_name` when directly connecting to OceanBase server. - *cluster_password*: Password for OceanBase when using configured `cluster_username`. - *first_start_timestamp*: Start timestamp in seconds, and zero means starting from now. -- *tb_white_list*: Table whitelist in format `tenant_name.database_name.table_name`, and `*` indicates any value. +- *tb_white_list*: Table whitelist in format `tenant_name.database_name.table_name`, `*` indicates any value, and multiple values can be separated by `|`. + +These parameters are used in `liboblog`, you can check the [doc](https://github.com/oceanbase/oceanbase-doc/blob/V3.1.2/zh-CN/9.supporting-tools/4.cdc/2.liboblog/2.liboblog-parameters/2.liboblog-configuration-items.md) for more details. Here is an example to set ObReaderConfig with a user of sys tenant, and the OceanBase and LogProxy server are on the same machine. @@ -73,7 +75,7 @@ config.setRsList("127.0.0.1:2882:2881"); config.setUsername("user@sys"); config.setPassword("pswd"); config.setStartTimestamp(0L); -config.setTableWhiteList("sys.*.*"); +config.setTableWhiteList("sys.db1.tb1|sys.db2.*"); ``` Once ObReaderConfig is set properly, you can use it to instance a LogProxyClient and listen to the log data. -- GitLab