connector.setLowResourceMaxIdleTime(value);
}
}
BoundedThreadPool threadPool = new BoundedThreadPool();
if (props.getProperty("min-threads") != null) {
int value = 0;
try {
value = Integer.parseInt(props.getProperty("min-threads").value);
} catch (NumberFormatException e) {
value = 0;
}
if (value > 0) {
threadPool.setMinThreads(value);
}
}
if (props.getProperty("max-threads") != null) {
int value = 0;
try {
value = Integer.parseInt(props.getProperty("max-threads").value);
} catch (NumberFormatException e) {
value = 0;
}
if (value > 0) {
threadPool.setMaxThreads(value);
}
}
if (props.getProperty("max-idle-time") != null) {
int value = 0;
try {
value = Integer.parseInt(props.getProperty("max-idle-time").value);
} catch (NumberFormatException e) {
value = 0;
}
if (value > 0) {
threadPool.setMaxIdleTimeMs(value);
}
}
if (props.getProperty("low-threads") != null) {
int value = 0;
try {
value = Integer.parseInt(props.getProperty("low-threads").value);
} catch (NumberFormatException e) {
value = 0;
}
if (value > 0) {
threadPool.setLowThreads(value);
}
}
connector.setThreadPool(threadPool);