Author: ffang
Date: Thu Aug 16 02:31:25 2012
New Revision: 1373704

URL: http://svn.apache.org/viewvc?rev=1373704&view=rev
Log:
Merged revisions 1373240 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1373240 | ffang | 2012-08-15 15:19:03 +0800 (δΈ‰, 15  8 2012) | 1 line
  
  [CXF-4475]LoggingInInterceptor throws when pretty printing MTOM messages
........

Modified:
    cxf/branches/2.6.x-fixes/   (props changed)
    
cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
    
cxf/branches/2.6.x-fixes/systests/databinding/src/test/java/org/apache/cxf/systest/jaxb/MTOMTest.java

Propchange: cxf/branches/2.6.x-fixes/
------------------------------------------------------------------------------
    svn:mergeinfo = /cxf/trunk:1373240

Propchange: cxf/branches/2.6.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: 
cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
URL: 
http://svn.apache.org/viewvc/cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java?rev=1373704&r1=1373703&r2=1373704&view=diff
==============================================================================
--- 
cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
 (original)
+++ 
cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
 Thu Aug 16 02:31:25 2012
@@ -148,7 +148,8 @@ public abstract class AbstractLoggingInt
                                 String encoding, String contentType) 
         throws Exception {
         // Just transform the XML message when the cos has content
-        if (isPrettyLogging() && (contentType != null && 
contentType.indexOf("xml") >= 0) && cos.size() > 0) {
+        if (isPrettyLogging() && (contentType != null && 
contentType.indexOf("xml") >= 0 
+            && contentType.toLowerCase().indexOf("multipart/related") < 0) && 
cos.size() > 0) {
             Transformer serializer = XMLUtils.newTransformer(2);
             // Setup indenting to "pretty print"
             serializer.setOutputProperty(OutputKeys.INDENT, "yes");

Modified: 
cxf/branches/2.6.x-fixes/systests/databinding/src/test/java/org/apache/cxf/systest/jaxb/MTOMTest.java
URL: 
http://svn.apache.org/viewvc/cxf/branches/2.6.x-fixes/systests/databinding/src/test/java/org/apache/cxf/systest/jaxb/MTOMTest.java?rev=1373704&r1=1373703&r2=1373704&view=diff
==============================================================================
--- 
cxf/branches/2.6.x-fixes/systests/databinding/src/test/java/org/apache/cxf/systest/jaxb/MTOMTest.java
 (original)
+++ 
cxf/branches/2.6.x-fixes/systests/databinding/src/test/java/org/apache/cxf/systest/jaxb/MTOMTest.java
 Thu Aug 16 02:31:25 2012
@@ -69,7 +69,7 @@ public class MTOMTest extends AbstractBu
         }
     }
     
-    @Logging
+    @Logging(pretty = true)
     @WebService
     @MTOM(threshold = 1)
     public interface MTOMService {


Reply via email to