Skip to content

Commit dedc279

Browse files
cameronbraidpaveltiunov
authored andcommitted
fix(clickhouse-driver): merging config with custom queryOptions which were not passing along the database (#100)
1 parent ff1b65d commit dedc279

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

packages/cubejs-clickhouse-driver/driver/ClickHouseDriver.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,14 @@ class ClickHouseDriver extends BaseDriver {
1717
...config
1818
};
1919
this.pool = genericPool.createPool({
20-
create: () => new ClickHouse(Object.assign({}, this.config, {
20+
create: () => new ClickHouse({
21+
...this.config,
2122
queryOptions: {
2223
join_use_nulls: 1,
23-
session_id: uuid()
24+
session_id: uuid(),
25+
...this.config.queryOptions,
2426
}
25-
})),
27+
}),
2628
destroy: () => Promise.resolve(),
2729
validate: async (connection) => {
2830
try {

0 commit comments

Comments
 (0)