diff options
author | Marc Laukien <marc@zeroc.com> | 2004-01-24 18:22:58 +0000 |
---|---|---|
committer | Marc Laukien <marc@zeroc.com> | 2004-01-24 18:22:58 +0000 |
commit | 34254149e244f71423dcbecec3192a55c5396ee7 (patch) | |
tree | 8dfd02d927d102e0806706d65551934b67c802c4 /java/src | |
parent | fix (diff) | |
download | ice-34254149e244f71423dcbecec3192a55c5396ee7.tar.bz2 ice-34254149e244f71423dcbecec3192a55c5396ee7.tar.xz ice-34254149e244f71423dcbecec3192a55c5396ee7.zip |
default thread pool size is now 1
Diffstat (limited to 'java/src')
-rw-r--r-- | java/src/IceInternal/Instance.java | 3 | ||||
-rw-r--r-- | java/src/IceInternal/ThreadPool.java | 7 |
2 files changed, 9 insertions, 1 deletions
diff --git a/java/src/IceInternal/Instance.java b/java/src/IceInternal/Instance.java index 24136efc7c9..ad1704c253b 100644 --- a/java/src/IceInternal/Instance.java +++ b/java/src/IceInternal/Instance.java @@ -189,6 +189,8 @@ public class Instance if(_clientThreadPool == null) // Lazy initialization. { +// Not necessary anymore, this is now the default for every thread pool +/* // // Make sure that the client thread pool defaults are // correctly. @@ -205,6 +207,7 @@ public class Instance { _properties.setProperty("Ice.ThreadPool.Client.SizeWarn", "0"); } +*/ _clientThreadPool = new ThreadPool(this, "Ice.ThreadPool.Client", 0); } diff --git a/java/src/IceInternal/ThreadPool.java b/java/src/IceInternal/ThreadPool.java index c8c3f4a65fa..9bdb06ea3ac 100644 --- a/java/src/IceInternal/ThreadPool.java +++ b/java/src/IceInternal/ThreadPool.java @@ -71,7 +71,12 @@ public final class ThreadPool // _keys = _selector.selectedKeys(); - int size = _instance.properties().getPropertyAsIntWithDefault(_prefix + ".Size", 5); + // + // We use just one thread as the default. This is the fastest + // possible setting, still allows one level of nesting, and + // doesn't require to make the servants thread safe. + // + int size = _instance.properties().getPropertyAsIntWithDefault(_prefix + ".Size", 1); if(size < 1) { size = 1; |