Skip to content

Commit df12360

Browse files
committed
drafted SNI config?
1 parent 8e7a796 commit df12360

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

client-v2/src/main/java/com/clickhouse/client/api/Client.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -594,6 +594,11 @@ public Builder useHttpCompression(boolean enabled) {
594594
return this;
595595
}
596596

597+
/**
598+
* Tell client that compression will be handled by application.
599+
* @param enabled - indicates that feature is enabled.
600+
* @return
601+
*/
597602
public Builder appCompressedData(boolean enabled) {
598603
this.configuration.put(ClientConfigProperties.APP_COMPRESSED_DATA.getKey(), String.valueOf(enabled));
599604
return this;

client-v2/src/test/java/com/clickhouse/client/internal/SmallTests.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package com.clickhouse.client.internal;
22

3+
import com.clickhouse.client.api.ClientConfigProperties;
34
import com.clickhouse.client.api.data_formats.internal.ProcessParser;
45
import com.clickhouse.client.api.metrics.OperationMetrics;
56
import com.clickhouse.client.api.metrics.ServerMetrics;
@@ -45,4 +46,19 @@ public void testTimezoneConvertion() {
4546
ZonedDateTime utcSameLocalDt = dt.withZoneSameLocal(ZoneId.of("UTC"));
4647
System.out.println("withZoneSameLocal: " + utcSameLocalDt);
4748
}
49+
50+
@Test
51+
public void testGenConfigParameters() {
52+
System.out.println("<br/> <br/> Default: `none` <br/> Enum: `none` <br/> Key: `none` "
53+
54+
55+
);
56+
for (ClientConfigProperties p : ClientConfigProperties.values()) {
57+
String defaultValue = p.getDefaultValue() == null ? "-" : "`" + p.getDefaultValue() + "`";
58+
System.out.println("<br/> <br/> Default: " +defaultValue + " <br/> Enum: `ClientConfigProperties." + p.name() + "` <br/> Key: `" + p.getKey() +"` "
59+
60+
61+
);
62+
}
63+
}
4864
}

0 commit comments

Comments
 (0)