我遇到的问题是,运行连接器时正在记录凭据,我不想记录这些凭据。任何线索都将不胜感激。
twh00eeo1#
尝试使用connection.password属性,记录时应屏蔽该值。像这样:
curl -X POST http://localhost:8083/connectors -H "Content-Type: application/json" -d \ '{ "name":"jdbc_source_mysql_01", "config":{ "connector.class":"io.confluent.connect.jdbc.JdbcSourceConnector" "connection.url":"jdbc:mysql://mysql:3306/demo", "connection.user":"connect_user", "connection.password":"password", "topic.prefix":"mysql-01-", "mode":"bulk" } }'
日志应该如下所示:
INFO JdbcSourceTaskConfig values: batch.max.rows = 100 connection.attempts = 3 connection.backoff.ms = 10000 connection.password = null connection.url = jdbc:mysql://*REDACTED*
1条答案
按热度按时间twh00eeo1#
尝试使用connection.password属性,记录时应屏蔽该值。像这样:
日志应该如下所示: