I am synchronizing data from 2 different DB using Kafka. But when running Kafka Connect to the oracle-source-connector file, I get an error: java.sql.SQLException: ORA-01005: null password given; logon denied.
Here is the details of my oracle-source-connector file
name=oracle-source-connector
connector.class=io.confluent.connect.jdbc.JdbcSourceConnector
tasks.max=1
connection.url=jdbc:oracle:thin:@//x.x.x.x:xxxx/khldbdev
connection.user=khldev
connection.password=khldev
table.whitelist=TABLE_TEST
mode=incrementing
incrementing.column.name=ID
topic.prefix=oracle_TABLE_TEST
My oracle DB still uses that account, no problem with the password. I also downloaded enough JDBC for the DB. I don’t understand why when kafka runs to that file it reports an error.
Thanks in advance.
M99 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
You can try couple of things to triage this issue further
- Check the Source Connector Properties file placed in the right directory where the worker is rightly pointed to
- Check any other DB client for the Connectivity test
- This is a generic error usually occurs, when the password field are not read correctly from the .properties file.
Also, you can try something similar as following (removing unwanted properties), if the issue with the properties file.
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/test",
"connection.user": "connect_user",
"connection.password": "connect_password",
"topic.prefix": "mysql-01-",
"poll.interval.ms" : 3600000,
"table.whitelist" : "test.accounts",
"mode":"bulk",
"transforms":"createKey,extractInt",
"transforms.createKey.type":"org.apache.kafka.connect.transforms.ValueToKey",
"transforms.createKey.fields":"id",
"transforms.extractInt.type":"org.apache.kafka.connect.transforms.ExtractField$Key",
"transforms.extractInt.field":"id"
}
}'