# 激活边端
curl -X POST 'http://localhost:8083/connectors' \
-H 'Content-Type: application/json' \
-d '{
  "name": "inventory-connector-v3",
  "config": {
    "connector.class": "io.debezium.connector.postgresql.PostgresConnector",
    "tasks.max": "5",
    "database.hostname": "postgres",
    "database.port": "5432",
    "database.user": "postgres",
    "database.password": "huansi.net@v3",
    "database.dbname" : "hsiotdb",
    "database.server.name": "iot-v3",
    "table.whitelist": "public.device,public.ts_kv_latest",
    "plugin.name": "pgoutput",
    "decimal.handling.mode": "string",
    "slot.name" : "slot1007"
  }
}'

# 查询
curl -X GET 'http://localhost:8083/connectors/inventory-connector-v3' 
curl --location --request GET 'http://localhost:8083/connectors/inventory-connector-v3/status'

# 删除
curl -X DETELE 'http://localhost:8083/connectors/inventory-connector-v3' 
curl --location --request DELETE 'http://localhost:8083/connectors/inventory-connector-v3'

# 查询卡夫卡
./kafka-console-consumer.sh --bootstrap-server localhost:29092 --topic iot-v3.public.ts_kv_latest  --from-beginning