felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fmesc...@apache.org
Subject svn commit: r1413487 - in /felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium: ConfigManagerBase.java ConfigurationAdminConfigurationPrinter.java
Date Mon, 26 Nov 2012 06:40:03 GMT
Author: fmeschbe
Date: Mon Nov 26 06:40:02 2012
New Revision: 1413487

URL: http://svn.apache.org/viewvc?rev=1413487&view=rev
Log:
FELIX-3783 use static strings for service names to prevent ClassNotFoundError's when the API
is not available

Modified:
    felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigManagerBase.java
    felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigurationAdminConfigurationPrinter.java

Modified: felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigManagerBase.java
URL: http://svn.apache.org/viewvc/felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigManagerBase.java?rev=1413487&r1=1413486&r2=1413487&view=diff
==============================================================================
--- felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigManagerBase.java
(original)
+++ felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigManagerBase.java
Mon Nov 26 06:40:02 2012
@@ -50,9 +50,9 @@ abstract class ConfigManagerBase extends
 
     private static final long serialVersionUID = -6691093960031418130L;
 
-    private static final String CONFIGURATION_ADMIN_NAME = ConfigurationAdmin.class.getName();
+    static final String CONFIGURATION_ADMIN_NAME = "org.osgi.service.cm.ConfigurationAdmin";
 
-    private static final String META_TYPE_NAME = MetaTypeService.class.getName();
+    static final String META_TYPE_NAME = "org.osgi.service.metatype.MetaTypeService";
 
 
     protected ConfigurationAdmin getConfigurationAdmin()

Modified: felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigurationAdminConfigurationPrinter.java
URL: http://svn.apache.org/viewvc/felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigurationAdminConfigurationPrinter.java?rev=1413487&r1=1413486&r2=1413487&view=diff
==============================================================================
--- felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigurationAdminConfigurationPrinter.java
(original)
+++ felix/trunk/webconsole/src/main/java/org/apache/felix/webconsole/internal/compendium/ConfigurationAdminConfigurationPrinter.java
Mon Nov 26 06:40:02 2012
@@ -55,8 +55,7 @@ public class ConfigurationAdminConfigura
      */
     public void printConfiguration(PrintWriter pw)
     {
-        ServiceReference sr = getBundleContext().getServiceReference(
-            ConfigurationAdmin.class.getName());
+        ServiceReference sr = getBundleContext().getServiceReference( ConfigManagerBase.CONFIGURATION_ADMIN_NAME
);
         if (sr == null)
         {
             pw.println("Status: Configuration Admin Service not available");



Mime
View raw message