cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject cxf git commit: [CXF-6402] Fixing checkstyle issues
Date Tue, 19 May 2015 12:15:29 GMT
Repository: cxf
Updated Branches:
  refs/heads/3.0.x-fixes 5c919818b -> c6db5cc0a


[CXF-6402] Fixing checkstyle issues


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/c6db5cc0
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/c6db5cc0
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/c6db5cc0

Branch: refs/heads/3.0.x-fixes
Commit: c6db5cc0a5abdf8f59739bde6139830717936ac1
Parents: 5c91981
Author: Sergey Beryozkin <sberyozkin@talend.com>
Authored: Tue May 19 13:15:09 2015 +0100
Committer: Sergey Beryozkin <sberyozkin@talend.com>
Committed: Tue May 19 13:15:09 2015 +0100

----------------------------------------------------------------------
 .../http_jetty/JettyHTTPServerEngine.java       | 24 ++++++++++++--------
 1 file changed, 14 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/c6db5cc0/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
----------------------------------------------------------------------
diff --git a/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
b/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
index b478396..87f313d 100644
--- a/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
+++ b/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPServerEngine.java
@@ -319,16 +319,7 @@ public class JettyHTTPServerEngine implements ServerEngine {
         if (shouldCheckUrl(handler.getBus())) {
             checkRegistedContext(url);
         }
-        if (contexts == null) {
-            contexts = new ContextHandlerCollection();
-            if (server != null) {
-                if (server.getHandler() instanceof ContextHandlerCollection) {
-                    contexts = (ContextHandlerCollection) server.getHandler();
-                } else {
-                    server.setHandler(contexts);
-                }
-            }
-        }
+        initializeContexts();
         
         SecurityHandler securityHandler = null;
         if (server == null) {
@@ -486,6 +477,19 @@ public class JettyHTTPServerEngine implements ServerEngine {
         ++servantCount;
     }
     
+    private void initializeContexts() {
+        if (contexts == null) {
+            contexts = new ContextHandlerCollection();
+            if (server != null) {
+                if (server.getHandler() instanceof ContextHandlerCollection) {
+                    contexts = (ContextHandlerCollection) server.getHandler();
+                } else {
+                    server.setHandler(contexts);
+                }
+            }
+        }
+    }
+
     protected void setupThreadPool() {
         AbstractConnector aconn = (AbstractConnector) connector;
         if (isSetThreadingParameters()) {


Mime
View raw message