cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1544637 - /cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/interceptor/AbstractMessageResponseTimeInterceptor.java
Date Fri, 22 Nov 2013 18:52:43 GMT
Author: sergeyb
Date: Fri Nov 22 18:52:43 2013
New Revision: 1544637

URL: http://svn.apache.org/r1544637
Log:
[CXF-5415] Escaping service and operation names when needed

Modified:
    cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/interceptor/AbstractMessageResponseTimeInterceptor.java

Modified: cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/interceptor/AbstractMessageResponseTimeInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/interceptor/AbstractMessageResponseTimeInterceptor.java?rev=1544637&r1=1544636&r2=1544637&view=diff
==============================================================================
--- cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/interceptor/AbstractMessageResponseTimeInterceptor.java
(original)
+++ cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/interceptor/AbstractMessageResponseTimeInterceptor.java
Fri Nov 22 18:52:43 2013
@@ -107,7 +107,7 @@ public abstract class AbstractMessageRes
             Service service = ex.get(Service.class);            
             Endpoint endpoint = ex.get(Endpoint.class);
             
-            String serviceName = "\"" + service.getName() + "\"";            
+            String serviceName = "\"" + escapePatternChars(service.getName().toString())
+ "\"";            
             String portName = "\"" + endpoint.getEndpointInfo().getName().getLocalPart()
+ "\"";
             
             OperationInfo opInfo = ex.get(OperationInfo.class);
@@ -152,7 +152,7 @@ public abstract class AbstractMessageRes
     protected String escapePatternChars(String value) {  
         // This can be replaced if really needed with pattern-based matching
         if (value.lastIndexOf(QUESTION_MARK) != -1) {
-            value.replace(QUESTION_MARK, ESCAPED_QUESTION_MARK);
+            value = value.replace(QUESTION_MARK, ESCAPED_QUESTION_MARK);
         }
         return value;
     }



Mime
View raw message