[Bug] sqlservercdc throw a NullPointerException when table name contains point #2439
Closed
1 of 2 tasks
Labels
bug
Something isn't working
Search before asking
Flink version
1.13.6
Flink CDC version
2.5-SNAPSHOT
Database and its version
sqlserver 2016
Minimal reproduce step
`SqlServerSourceBuilder.SqlServerIncrementalSource sqlServerSource =
new SqlServerSourceBuilder()
.hostname("10.10.17.35")
.port(1433)
.databaseList("CRDB")
.tableList("dbo.tCR0021_V2.0")
.username("app")
.password("app127")
.deserializer(new JsonDebeziumDeserializationSchema())
.startupOptions(StartupOptions.initial())
.build();
StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment();
// enable checkpoint
// set the source parallelism to 2
What did you expect to see?
正常执行
What did you see instead?
Executing this code throws a NullPointerException
Caused by: java.lang.RuntimeException: SplitFetcher thread 0 received unexpected exception while polling the records
at org.apache.flink.connector.base.source.reader.fetcher.SplitFetcher.runOnce(SplitFetcher.java:150)
at org.apache.flink.connector.base.source.reader.fetcher.SplitFetcher.run(SplitFetcher.java:105)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run$$$capture(FutureTask.java:266)
at java.util.concurrent.FutureTask.run(FutureTask.java)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
... 1 more
Caused by: org.apache.flink.util.FlinkRuntimeException: Read split SnapshotSplit{tableId=CRDB.dbo.tCR0021_V2, splitId='CRDB.dbo.tCR0021_V2.0:1', splitKeyType=[
ID
INT NOT NULL], splitStart=[9084], splitEnd=[18167], highWatermark=null} error due to java.lang.NullPointerException.at com.ververica.cdc.connectors.base.source.reader.external.IncrementalSourceScanFetcher.checkReadException(IncrementalSourceScanFetcher.java:182)
at com.ververica.cdc.connectors.base.source.reader.external.IncrementalSourceScanFetcher.pollSplitRecords(IncrementalSourceScanFetcher.java:129)
at com.ververica.cdc.connectors.base.source.reader.IncrementalSourceSplitReader.fetch(IncrementalSourceSplitReader.java:73)
at org.apache.flink.connector.base.source.reader.fetcher.FetchTask.run(FetchTask.java:58)
at org.apache.flink.connector.base.source.reader.fetcher.SplitFetcher.runOnce(SplitFetcher.java:142)
... 7 more
Caused by: io.debezium.DebeziumException: java.lang.NullPointerException
at com.ververica.cdc.connectors.sqlserver.source.reader.fetch.SqlServerScanFetchTask$SqlServerSnapshotSplitReadTask.execute(SqlServerScanFetchTask.java:262)
at com.ververica.cdc.connectors.sqlserver.source.reader.fetch.SqlServerScanFetchTask.execute(SqlServerScanFetchTask.java:94)
at com.ververica.cdc.connectors.base.source.reader.external.IncrementalSourceScanFetcher.lambda$submitTask$0(IncrementalSourceScanFetcher.java:95)
... 6 more
Caused by: java.lang.NullPointerException
at com.ververica.cdc.connectors.sqlserver.source.reader.fetch.SqlServerScanFetchTask$SqlServerSnapshotSplitReadTask.createDataEventsForTable(SqlServerScanFetchTask.java:335)
at com.ververica.cdc.connectors.sqlserver.source.reader.fetch.SqlServerScanFetchTask$SqlServerSnapshotSplitReadTask.createDataEvents(SqlServerScanFetchTask.java:319)
at com.ververica.cdc.connectors.sqlserver.source.reader.fetch.SqlServerScanFetchTask$SqlServerSnapshotSplitReadTask.doExecute(SqlServerScanFetchTask.java:289)
at com.ververica.cdc.connectors.sqlserver.source.reader.fetch.SqlServerScanFetchTask$SqlServerSnapshotSplitReadTask.execute(SqlServerScanFetchTask.java:257)
... 8 more
Anything else?
No response
Are you willing to submit a PR?
The text was updated successfully, but these errors were encountered: