- if (properties != null) {
- for (String property : properties.keySet()) {
- String value = properties.get(property);
- String bcValue = bundleContext.getProperty(property);
- if (PROP_OSGI_CONFIGURATION_AREA.equals(property) || PROP_OSGI_INSTANCE_AREA.equals(property)) {
- try {
- URL uri = new URL(value);
- URL bcUri = new URL(bcValue);
- if (!uri.equals(bcUri))
- throw new IllegalArgumentException("Property " + property + "=" + uri
- + " is inconsistent with bundle context : " + bcUri);
- } catch (MalformedURLException e) {
- throw new IllegalArgumentException("Malformed property " + property, e);
- }
-
- } else {
- if (!value.equals(bcValue))
- throw new IllegalArgumentException("Property " + property + "=" + value
- + " is inconsistent with bundle context : " + bcValue);
- }
- }
- } else {
- String useSystemProperties = bundleContext.getProperty(PROP_OSGI_USE_SYSTEM_PROPERTIES);
- if (useSystemProperties == null || !useSystemProperties.equals("true")) {
- OsgiBootUtils.warn("No properties passed but " + PROP_OSGI_USE_SYSTEM_PROPERTIES + " is not set.");
- }
- }
+// if (properties != null) {
+// for (String property : properties.keySet()) {
+// String value = properties.get(property);
+// String bcValue = bundleContext.getProperty(property);
+// if (PROP_OSGI_CONFIGURATION_AREA.equals(property) || PROP_OSGI_INSTANCE_AREA.equals(property)) {
+// try {
+// if (value.startsWith("/"))
+// value = "file://" + value;
+// URL uri = new URL(value);
+// URL bcUri = new URL(bcValue);
+// if (!uri.equals(bcUri))
+// throw new IllegalArgumentException("Property " + property + "=" + uri
+// + " is inconsistent with bundle context : " + bcUri);
+// } catch (MalformedURLException e) {
+// throw new IllegalArgumentException("Malformed property " + property, e);
+// }
+//
+// } else {
+// if (!value.equals(bcValue))
+// throw new IllegalArgumentException("Property " + property + "=" + value
+// + " is inconsistent with bundle context : " + bcValue);
+// }
+// }
+// } else {
+// String useSystemProperties = bundleContext.getProperty(PROP_OSGI_USE_SYSTEM_PROPERTIES);
+// if (useSystemProperties == null || !useSystemProperties.equals("true")) {
+// OsgiBootUtils.warn("No properties passed but " + PROP_OSGI_USE_SYSTEM_PROPERTIES + " is not set.");
+// }
+// }