servicemix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1465021 - /servicemix/smx4/specs/trunk/jaxws-api-2.2/src/main/java/javax/xml/ws/spi/FactoryFinder.java
Date Fri, 05 Apr 2013 15:55:24 GMT
Author: dkulp
Date: Fri Apr  5 15:55:23 2013
New Revision: 1465021

URL: http://svn.apache.org/r1465021
Log:
Add some debugging info and a system property to turn it on.

Modified:
    servicemix/smx4/specs/trunk/jaxws-api-2.2/src/main/java/javax/xml/ws/spi/FactoryFinder.java

Modified: servicemix/smx4/specs/trunk/jaxws-api-2.2/src/main/java/javax/xml/ws/spi/FactoryFinder.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/specs/trunk/jaxws-api-2.2/src/main/java/javax/xml/ws/spi/FactoryFinder.java?rev=1465021&r1=1465020&r2=1465021&view=diff
==============================================================================
--- servicemix/smx4/specs/trunk/jaxws-api-2.2/src/main/java/javax/xml/ws/spi/FactoryFinder.java
(original)
+++ servicemix/smx4/specs/trunk/jaxws-api-2.2/src/main/java/javax/xml/ws/spi/FactoryFinder.java
Fri Apr  5 15:55:23 2013
@@ -45,11 +45,21 @@ class FactoryFinder {
     /**
      * Set to true for debugging.
      */
-    private static final boolean debug = false;
+    private static final boolean debug;
+    static {
+        boolean b = false;
+        try {
+            b = Boolean.getBoolean("javax.xml.ws.spi.debug");
+        } catch (Throwable t) {
+            b = false;
+        }
+        debug = b;
+    }
+    
 
     private static void debugPrintln(String msg) {
         if (debug) {
-            System.err.println("Factory Finder:" + msg);
+            System.err.println("JAX-WS Factory Finder: " + msg);
         }
     }
 
@@ -182,7 +192,10 @@ class FactoryFinder {
                         }
                         Class spiClass = org.apache.servicemix.specs.locator.OsgiLocator.locate(factoryClass,
iFactoryId);
                         if (spiClass != null) {
+                            debugPrintln("Found spiClass: " + spiClass);
                             return spiClass.newInstance();
+                        } else {
+                            debugPrintln("No spiClass found in OSGi");
                         }
                      } catch (Throwable e) {
                         if (debug) e.printStackTrace();



Mime
View raw message