cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1515510 - in /cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws: WrapperClassGenerator.java support/JaxWsServiceFactoryBean.java
Date Mon, 19 Aug 2013 16:50:51 GMT
Author: dkulp
Date: Mon Aug 19 16:50:51 2013
New Revision: 1515510

URL: http://svn.apache.org/r1515510
Log:
Merged revisions 1515499 via  git cherry-pick from
https://svn.apache.org/repos/asf/cxf/branches/2.7.x-fixes

........
  r1515499 | dkulp | 2013-08-19 12:32:01 -0400 (Mon, 19 Aug 2013) | 10 lines

  Merged revisions 1515487 via  git cherry-pick from
  https://svn.apache.org/repos/asf/cxf/trunk

  ........
    r1515487 | dkulp | 2013-08-19 12:12:15 -0400 (Mon, 19 Aug 2013) | 2 lines

    Slight optimization to avoid checking the ASM stuff unless it's actually needed

  ........

........

Modified:
    cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/WrapperClassGenerator.java
    cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsServiceFactoryBean.java

Modified: cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/WrapperClassGenerator.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/WrapperClassGenerator.java?rev=1515510&r1=1515509&r2=1515510&view=diff
==============================================================================
--- cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/WrapperClassGenerator.java
(original)
+++ cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/WrapperClassGenerator.java
Mon Aug 19 16:50:51 2013
@@ -110,21 +110,6 @@ public final class WrapperClassGenerator
     }
 
     public Set<Class<?>> generate() {
-        try {
-            if (createClassWriter() == null) {
-                throw new ClassNotFoundException();
-            }
-        } catch (Throwable t) {
-            for (OperationInfo opInfo : interfaceInfo.getOperations()) {
-                if (opInfo.isUnwrappedCapable()
-                    && (opInfo.getUnwrappedOperation()
-                        .getProperty(ReflectionServiceFactoryBean.WRAPPERGEN_NEEDED) != null))
{
-                    LOG.warning(opInfo.getName() + "requires a wrapper bean but problems
with"
-                                + " ASM has prevented creating one.  Operation may not work
correctly.");
-                }
-            }
-            return wrapperBeans;
-        }
         for (OperationInfo opInfo : interfaceInfo.getOperations()) {
             if (opInfo.isUnwrappedCapable()) {
                 Method method = (Method)opInfo.getProperty(ReflectionServiceFactoryBean.METHOD);
@@ -162,11 +147,16 @@ public final class WrapperClassGenerator
                                         Method method, 
                                         boolean isRequest) {
 
+
+        ClassWriter cw = createClassWriter();
+        if (cw == null) {
+            LOG.warning(op.getName() + "requires a wrapper bean but problems with"
+                + " ASM has prevented creating one.  Operation may not work correctly.");
+            return;
+        }
         QName wrapperElement = messageInfo.getName();
-        
         boolean anonymous = factory.getAnonymousWrapperTypes();
 
-        ClassWriter cw = createClassWriter();
         String pkg = getPackageName(method) + ".jaxws_asm" + (anonymous ? "_an" : "");
         String className =  pkg + "." 
             + StringUtils.capitalize(op.getName().getLocalPart());

Modified: cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsServiceFactoryBean.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsServiceFactoryBean.java?rev=1515510&r1=1515509&r2=1515510&view=diff
==============================================================================
--- cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsServiceFactoryBean.java
(original)
+++ cxf/branches/2.6.x-fixes/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/support/JaxWsServiceFactoryBean.java
Mon Aug 19 16:50:51 2013
@@ -107,7 +107,6 @@ public class JaxWsServiceFactoryBean ext
     private List<WebServiceFeature> setWsFeatures;
     private List<WebServiceFeature> wsFeatures;
 
-    private boolean wrapperBeanGenerated;
     private Set<Class<?>> wrapperClasses;
 
 
@@ -132,7 +131,6 @@ public class JaxWsServiceFactoryBean ext
     @Override
     public void reset() {
         super.reset();
-        wrapperBeanGenerated = false;
         wrapperClasses = null;
     }
 
@@ -634,9 +632,7 @@ public class JaxWsServiceFactoryBean ext
     @Override
     protected Set<Class<?>> getExtraClass() {
         Set<Class<?>> classes = new HashSet<Class<?>>();
-        if (!wrapperBeanGenerated) {
-            wrapperClasses = generatedWrapperBeanClass();
-        }
+        wrapperClasses = generatedWrapperBeanClass();
         if (wrapperClasses != null) {
             classes.addAll(wrapperClasses);
         }



Mime
View raw message