Skip to content

Commit 46496f5

Browse files
committed
updated runner config
1 parent 6d0e255 commit 46496f5

File tree

2 files changed

+13
-9
lines changed

2 files changed

+13
-9
lines changed

performance/src/test/com/clickhouse/benchmark/BenchmarkRunner.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,19 +36,19 @@ public static void main(String[] args) throws Exception {
3636

3737
Options opt = new OptionsBuilder()
3838
.include(QueryClient.class.getSimpleName())
39-
// .include(InsertClient.class.getSimpleName())
40-
// .include(Compression.class.getSimpleName())
41-
// .include(Serializers.class.getSimpleName())
42-
// .include(Deserializers.class.getSimpleName())
43-
// .include(MixedWorkload.class.getSimpleName())
39+
.include(InsertClient.class.getSimpleName())
40+
.include(Compression.class.getSimpleName())
41+
.include(Serializers.class.getSimpleName())
42+
.include(Deserializers.class.getSimpleName())
43+
.include(MixedWorkload.class.getSimpleName())
4444
.forks(1) // must be a fork. No fork only for debugging
4545
.mode(Mode.SampleTime)
4646
.timeUnit(TimeUnit.MILLISECONDS)
4747
.addProfiler(GCProfiler.class)
4848
.addProfiler(MemPoolProfiler.class)
49-
.warmupIterations(1)
49+
.warmupIterations(3)
5050
.warmupTime(TimeValue.seconds(10))
51-
.measurementIterations(5)
51+
.measurementIterations(10)
5252
.jvmArgs("-Xms8g", "-Xmx8g")
5353
.measurementTime(TimeValue.seconds(isCloud() ? 30 : 10))
5454
.resultFormat(ResultFormatType.JSON)

performance/src/test/com/clickhouse/benchmark/clients/BenchmarkBase.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
import com.clickhouse.client.ClickHouseProtocol;
1313
import com.clickhouse.client.ClickHouseResponse;
1414
import com.clickhouse.client.api.Client;
15+
import com.clickhouse.client.api.ConnectionReuseStrategy;
1516
import com.clickhouse.client.api.enums.Protocol;
1617
import com.clickhouse.client.api.insert.InsertResponse;
1718
import com.clickhouse.client.api.query.GenericRecord;
@@ -208,8 +209,11 @@ public static boolean verifyCount(String tableName, long expectedCount) {
208209
}
209210

210211
protected static ClickHouseClient getClientV1() {
211-
//We get a new client so that closing won't affect other subsequent calls
212-
return ClickHouseClient.newInstance(ClickHouseCredentials.fromUserAndPassword(getUsername(), getPassword()), ClickHouseProtocol.HTTP);
212+
// We get a new client so that closing won't affect other subsequent calls
213+
return ClickHouseClient.builder()
214+
.defaultCredentials(ClickHouseCredentials.fromUserAndPassword(getUsername(), getPassword()))
215+
.nodeSelector(ClickHouseNodeSelector.of(ClickHouseProtocol.HTTP))
216+
.build();
213217
}
214218
protected static Client getClientV2() {
215219
return getClientV2(true);

0 commit comments

Comments
 (0)