Skip to content

代码疑问:CK批量写入代码为什么每次批量写入后就关闭了statement ? #625

@baoyubobo

Description

@baoyubobo

类: io.github.interestinglab.waterdrop.output.batch.Clickhouse

方法:private def execute(statement: ClickHousePreparedStatement, retry: Int)

为什么上述方法中 statement.executeBatch() 执行成功后,就执行 statement.close() 关闭了该statement对象?
该方法在代码中有多调用,如果第一次执行就关闭掉statement,那么后续执行会报错呀?

image

麻烦解答一下我的疑问!
谢谢!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions