Skip to content

[client-v2] Concurrent use of InsertSetting may lead to a wrong settings set to a final request #2543

@chernser

Description

@chernser

Description

There are a few concerns about settings object

  • Its documentation doesn't tell anything about thread-safety
  • When same object is used for concurrent operation it may lead that one operation will override settings of another because internally settings objects being changed.

Here is an example: https://github.com/ClickHouse/clickhouse-java/blob/v0.8.3/client-v2/src/main/java/com/clickhouse/client/api/Client.java#L1562

It show that query parameters are calculated and set to the settings. If settings are shared between thread who knows what may happen.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions