cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject git commit: [CXF-6038] Only add the handler interceptors once This closes #26
Date Tue, 21 Oct 2014 20:15:48 GMT
Repository: cxf
Updated Branches:
  refs/heads/master da9070b37 -> 80ea71977


[CXF-6038] Only add the handler interceptors once
This closes #26

Signed-off-by: Daniel Kulp <dkulp@apache.org>


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

Branch: refs/heads/master
Commit: 80ea7197789ffb8720827aa9291fc4f40c09580d
Parents: da9070b
Author: Kyle Lape <kyle.lape@redhat.com>
Authored: Fri Oct 10 14:34:07 2014 -0700
Committer: Daniel Kulp <dkulp@apache.org>
Committed: Tue Oct 21 16:15:36 2014 -0400

----------------------------------------------------------------------
 .../apache/cxf/jaxws/support/JaxWsEndpointImpl.java    | 13 +++++++++++++
 1 file changed, 13 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/80ea7197/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
----------------------------------------------------------------------
diff --git a/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
b/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
index accc5f4..6f0be97 100644
--- a/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
+++ b/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsEndpointImpl.java
@@ -123,6 +123,7 @@ public class JaxWsEndpointImpl extends EndpointImpl {
     private SOAPHandlerFaultOutInterceptor soapFaultOutInterceptor;
     private LogicalHandlerFaultInInterceptor logicalFaultInInterceptor;
     private SOAPHandlerFaultInInterceptor soapFaultInInterceptor;
+    private boolean handlerInterceptorsAdded;
         
     public JaxWsEndpointImpl(Bus bus, Service s, EndpointInfo ei) throws EndpointException
{
         this(bus, s, ei, null, null, null, true);
@@ -543,6 +544,12 @@ public class JaxWsEndpointImpl extends EndpointImpl {
     }
 
     public void addHandlerInterceptors() {
+        if (handlerInterceptorsAdded) {
+            return;
+        } 
+
+        handlerInterceptorsAdded = true;
+
         List<Interceptor<? extends Message>> in = super.getInInterceptors();
      
         List<Interceptor<? extends Message>> out = super.getOutInterceptors();
         List<Interceptor<? extends Message>> outFault = super.getOutFaultInterceptors();
   
@@ -564,6 +571,12 @@ public class JaxWsEndpointImpl extends EndpointImpl {
         }
     }
     public void removeHandlerInterceptors() {
+        if (!handlerInterceptorsAdded) {
+            return;
+        }
+
+        handlerInterceptorsAdded = false;
+
         List<Interceptor<? extends Message>> in = super.getInInterceptors();
      
         List<Interceptor<? extends Message>> out = super.getOutInterceptors();
         List<Interceptor<? extends Message>> outFault = super.getOutFaultInterceptors();
   


Mime
View raw message