|
26 | 26 | */ |
27 | 27 | public class ClickHouseConfig implements Serializable { |
28 | 28 | static final class ClientOptions { |
29 | | - private static final ClientOptions instance = new ClientOptions(); |
| 29 | + private static final ClientOptions INSTANCE = new ClientOptions(); |
30 | 30 |
|
31 | 31 | private final Map<String, ClickHouseOption> customOptions; |
32 | 32 |
|
@@ -138,7 +138,7 @@ protected static final Object mergeMetricRegistry(List<ClickHouseConfig> list) { |
138 | 138 | public static Map<ClickHouseOption, Serializable> toClientOptions(Map<?, ?> props) { |
139 | 139 | Map<ClickHouseOption, Serializable> options = new HashMap<>(); |
140 | 140 | if (props != null && !props.isEmpty()) { |
141 | | - Map<String, ClickHouseOption> customOptions = ClientOptions.instance.customOptions; |
| 141 | + Map<String, ClickHouseOption> customOptions = ClientOptions.INSTANCE.customOptions; |
142 | 142 | for (Entry<?, ?> e : props.entrySet()) { |
143 | 143 | if (e.getKey() == null || e.getValue() == null) { |
144 | 144 | continue; |
@@ -202,6 +202,7 @@ public static Map<ClickHouseOption, Serializable> toClientOptions(Map<?, ?> prop |
202 | 202 | private final String sslKey; |
203 | 203 | private final boolean useBlockingQueue; |
204 | 204 | private final boolean useObjectsInArray; |
| 205 | + private final boolean useNoProxy; |
205 | 206 | private final boolean useServerTimeZone; |
206 | 207 | private final boolean useServerTimeZoneForDates; |
207 | 208 | private final TimeZone timeZoneForDate; |
@@ -297,6 +298,7 @@ public ClickHouseConfig(Map<ClickHouseOption, Serializable> options, ClickHouseC |
297 | 298 | this.sslKey = (String) getOption(ClickHouseClientOption.SSL_KEY); |
298 | 299 | this.useBlockingQueue = (boolean) getOption(ClickHouseClientOption.USE_BLOCKING_QUEUE); |
299 | 300 | this.useObjectsInArray = (boolean) getOption(ClickHouseClientOption.USE_OBJECTS_IN_ARRAYS); |
| 301 | + this.useNoProxy = (boolean) getOption(ClickHouseClientOption.USE_NO_PROXY); |
300 | 302 | this.useServerTimeZone = (boolean) getOption(ClickHouseClientOption.USE_SERVER_TIME_ZONE); |
301 | 303 | this.useServerTimeZoneForDates = (boolean) getOption(ClickHouseClientOption.USE_SERVER_TIME_ZONE_FOR_DATES); |
302 | 304 |
|
@@ -649,6 +651,10 @@ public boolean isUseObjectsInArray() { |
649 | 651 | return useObjectsInArray; |
650 | 652 | } |
651 | 653 |
|
| 654 | + public boolean isUseNoProxy() { |
| 655 | + return useNoProxy; |
| 656 | + } |
| 657 | + |
652 | 658 | public boolean isUseServerTimeZone() { |
653 | 659 | return useServerTimeZone; |
654 | 660 | } |
|
0 commit comments