ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject incubator-ignite git commit: #IGNITE-160 Fixed rest
Date Mon, 09 Feb 2015 09:27:29 GMT
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-160 a05fb6650 -> 2307f7404


#IGNITE-160 Fixed rest


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/2307f740
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/2307f740
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/2307f740

Branch: refs/heads/ignite-160
Commit: 2307f7404ce1d2069dbaaddc591a4ca4ea8ca3e6
Parents: a05fb66
Author: nikolay_tikhonov <ntikhonov@gridgain.com>
Authored: Mon Feb 9 12:17:29 2015 +0300
Committer: nikolay_tikhonov <ntikhonov@gridgain.com>
Committed: Mon Feb 9 12:17:29 2015 +0300

----------------------------------------------------------------------
 .../org/apache/ignite/internal/IgnitionEx.java  | 42 ++++++--------------
 1 file changed, 12 insertions(+), 30 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2307f740/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java b/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
index ac8aa14..ac664d3 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
@@ -1393,28 +1393,7 @@ public class IgnitionEx {
 
             ClientConnectionConfiguration clientCfg = cfg.getClientConnectionConfiguration();
 
-            if (clientCfg == null) {
-                clientCfg = new ClientConnectionConfiguration();
-
-                clientCfg.setClientMessageInterceptor(cfg.getClientMessageInterceptor());
-                clientCfg.setRestAccessibleFolders(cfg.getRestAccessibleFolders());
-                clientCfg.setRestIdleTimeout(cfg.getRestIdleTimeout());
-                clientCfg.setRestJettyPath(cfg.getRestJettyPath());
-                clientCfg.setRestPortRange(cfg.getRestPortRange());
-                clientCfg.setRestSecretKey(cfg.getRestSecretKey());
-                clientCfg.setRestTcpDirectBuffer(cfg.isRestTcpDirectBuffer());
-                clientCfg.setRestTcpHost(cfg.getRestTcpHost());
-                clientCfg.setRestTcpNoDelay(cfg.isRestTcpNoDelay());
-                clientCfg.setRestTcpPort(cfg.getRestTcpPort());
-                clientCfg.setRestTcpReceiveBufferSize(cfg.getRestTcpReceiveBufferSize());
-                clientCfg.setRestTcpSelectorCount(cfg.getRestTcpSelectorCount());
-                clientCfg.setRestTcpSendBufferSize(cfg.getRestTcpSendBufferSize());
-                clientCfg.setRestTcpSendQueueLimit(cfg.getRestTcpSendQueueLimit());
-                clientCfg.setRestTcpSslClientAuth(cfg.isRestTcpSslClientAuth());
-                clientCfg.setRestTcpSslContextFactory(cfg.getRestTcpSslContextFactory());
-                clientCfg.setRestTcpSslEnabled(cfg.isRestTcpSslEnabled());
-            }
-            else
+            if (clientCfg != null)
                 clientCfg = new ClientConnectionConfiguration(clientCfg);
 
 
@@ -1531,13 +1510,15 @@ public class IgnitionEx {
                 0,
                 new LinkedBlockingQueue<Runnable>());
 
-            restExecSvc = new IgniteThreadPoolExecutor(
-                "rest-" + cfg.getGridName(),
-                clientCfg.getRestThreadPoolSize(),
-                clientCfg.getRestThreadPoolSize(),
-                DFLT_REST_KEEP_ALIVE_TIME,
-                new LinkedBlockingQueue<Runnable>(DFLT_REST_THREADPOOL_QUEUE_CAP)
-            );
+            if (clientCfg != null) {
+                restExecSvc = new IgniteThreadPoolExecutor(
+                    "rest-" + cfg.getGridName(),
+                    clientCfg.getRestThreadPoolSize(),
+                    clientCfg.getRestThreadPoolSize(),
+                    DFLT_REST_KEEP_ALIVE_TIME,
+                    new LinkedBlockingQueue<Runnable>(DFLT_REST_THREADPOOL_QUEUE_CAP)
+                );
+            }
 
             utilityCacheExecSvc = new IgniteThreadPoolExecutor(
                 "utility-" + cfg.getGridName(),
@@ -2172,7 +2153,8 @@ public class IgnitionEx {
 
             ggfsExecSvc = null;
 
-            U.shutdownNow(getClass(), restExecSvc, log);
+            if (restExecSvc != null)
+                U.shutdownNow(getClass(), restExecSvc, log);
 
             restExecSvc = null;
 


Mime
View raw message