|
@@ -27,6 +27,7 @@ public class BizConfig extends RefreshableConfig {
|
|
|
private static final int DEFAULT_RELEASE_MESSAGE_SCAN_INTERVAL_IN_MS = 1000; //1000ms
|
|
|
private static final int DEFAULT_RELEASE_MESSAGE_NOTIFICATION_BATCH = 100;
|
|
|
private static final int DEFAULT_RELEASE_MESSAGE_NOTIFICATION_BATCH_INTERVAL_IN_MILLI = 100;//100ms
|
|
|
+ private static final int DEFAULT_LONG_POLLING_TIMEOUT = 60; //60s
|
|
|
|
|
|
private Gson gson = new Gson();
|
|
|
private static final Type namespaceValueLengthOverrideTypeReference =
|
|
@@ -58,6 +59,11 @@ public class BizConfig extends RefreshableConfig {
|
|
|
return checkInt(interval, 1, Integer.MAX_VALUE, DEFAULT_GRAY_RELEASE_RULE_SCAN_INTERVAL);
|
|
|
}
|
|
|
|
|
|
+ public long longPollingTimeout() {
|
|
|
+ int timeout = getIntProperty("long.polling.timeout", DEFAULT_LONG_POLLING_TIMEOUT);
|
|
|
+ return 1000 * checkInt(timeout, 1, Integer.MAX_VALUE, DEFAULT_LONG_POLLING_TIMEOUT);
|
|
|
+ }
|
|
|
+
|
|
|
public int itemKeyLengthLimit() {
|
|
|
int limit = getIntProperty("item.key.length.limit", DEFAULT_ITEM_KEY_LENGTH);
|
|
|
return checkInt(limit, 5, Integer.MAX_VALUE, DEFAULT_ITEM_KEY_LENGTH);
|
|
@@ -146,4 +152,5 @@ public class BizConfig extends RefreshableConfig {
|
|
|
}
|
|
|
return defaultValue;
|
|
|
}
|
|
|
+
|
|
|
}
|