You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "zhanghuaibei (Jira)" <ji...@apache.org> on 2024/08/19 00:58:00 UTC

[jira] [Commented] (FLINK-36044) In flink-connector-mysql-cdc-2.4.0 version, scan.snapshot.fetch.size does not take effect

    [ https://issues.apache.org/jira/browse/FLINK-36044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17874751#comment-17874751 ] 

zhanghuaibei commented on FLINK-36044:
--------------------------------------

Why hasn't anyone answered

> In flink-connector-mysql-cdc-2.4.0 version, scan.snapshot.fetch.size does not take effect
> -----------------------------------------------------------------------------------------
>
>                 Key: FLINK-36044
>                 URL: https://issues.apache.org/jira/browse/FLINK-36044
>             Project: Flink
>          Issue Type: Bug
>          Components: Flink CDC
>            Reporter: zhanghuaibei
>            Priority: Major
>              Labels: CDC
>             Fix For: cdc-3.1.0
>
>
> In version 2.4 of the code, scan.snapshot.fetch.size was not read and loaded. In this version, how to implement MySQL stream reading, useCursorfetch=true, and debezium.snapshot.fetch.size for processing? can set Interger.MIN_VALUE?
> Is ResultSet.TYPE-FORWARD_ONLY necessary?
>  
> flink-connector-mysql-cdc/src/main/java/com/ververica/cdc/connectors/mysql/source/utils/StatementUtils.java, 
> private static PreparedStatement initStatement(JdbcConnection jdbc, String sql, int fetchSize)
> throws SQLException {
> final Connection connection = jdbc.connection();
> connection.setAutoCommit(false);
> final PreparedStatement statement = connection.prepareStatement(sql);
> statement.setFetchSize(fetchSize);
> return statement;
> },Is this writing method correct?
> This configuration does not work, and does it have a big impact on memory?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)