This is an automated email from the ASF dual-hosted git repository.

jbonofre pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/karaf.git


The following commit(s) were added to refs/heads/main by this push:
     new ea71d6b2ba Bump org.eclipse.platform:org.eclipse.osgi from 3.18.0 to 
3.24.100 (#2303)
ea71d6b2ba is described below

commit ea71d6b2baa2ce5435077f24d88158871a766f7b
Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
AuthorDate: Sun Mar 15 18:44:09 2026 +0100

    Bump org.eclipse.platform:org.eclipse.osgi from 3.18.0 to 3.24.100 (#2303)
    
    * Bump org.eclipse.platform:org.eclipse.osgi from 3.18.0 to 3.24.100
    
    Bumps 
[org.eclipse.platform:org.eclipse.osgi](https://github.com/eclipse-equinox/equinox)
 from 3.18.0 to 3.24.100.
    - [Commits](https://github.com/eclipse-equinox/equinox/commits)
    
    ---
    updated-dependencies:
    - dependency-name: org.eclipse.platform:org.eclipse.osgi
      dependency-version: 3.24.100
      dependency-type: direct:development
      update-type: version-update:semver-minor
    ...
    
    Signed-off-by: dependabot[bot] <[email protected]>
    
    * Fix framework factory loading to skip comments in service loader files
    
    The loadFrameworkFactory() method reads 
META-INF/services/org.osgi.framework.launch.FrameworkFactory
    to discover the framework factory class. It was reading only the first 
line, but the Java ServiceLoader
    specification allows comment lines starting with '#'. Equinox 3.24.100 now 
includes a '# Generated by bnd'
    comment, causing a ClassNotFoundException and preventing the framework from 
starting.
    
    ---------
    
    Signed-off-by: dependabot[bot] <[email protected]>
    Co-authored-by: dependabot[bot] 
<49699333+dependabot[bot]@users.noreply.github.com>
    Co-authored-by: JB Onofré <[email protected]>
---
 main/src/main/java/org/apache/karaf/main/Main.java | 9 ++++++++-
 pom.xml                                            | 2 +-
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/main/src/main/java/org/apache/karaf/main/Main.java 
b/main/src/main/java/org/apache/karaf/main/Main.java
index 0793861883..2fe5717216 100644
--- a/main/src/main/java/org/apache/karaf/main/Main.java
+++ b/main/src/main/java/org/apache/karaf/main/Main.java
@@ -537,7 +537,14 @@ public class Main {
         if (factoryClass == null) {
             InputStream is = 
classLoader.getResourceAsStream("META-INF/services/" + 
FrameworkFactory.class.getName());
             BufferedReader br = new BufferedReader(new InputStreamReader(is, 
StandardCharsets.UTF_8));
-            factoryClass = br.readLine();
+            String line;
+            while ((line = br.readLine()) != null) {
+                line = line.trim();
+                if (!line.isEmpty() && !line.startsWith("#")) {
+                    factoryClass = line;
+                    break;
+                }
+            }
             br.close();
         }
         FrameworkFactory factory = (FrameworkFactory) 
classLoader.loadClass(factoryClass).newInstance();
diff --git a/pom.xml b/pom.xml
index ecd46fbece..e896690cbf 100644
--- a/pom.xml
+++ b/pom.xml
@@ -202,7 +202,7 @@
         <easymock.version>5.6.0</easymock.version>
         <equinox.groupId>org.eclipse.platform</equinox.groupId>
         <equinox.artifactId>org.eclipse.osgi</equinox.artifactId>
-        <equinox.version>3.18.0</equinox.version>
+        <equinox.version>3.24.100</equinox.version>
         <equinox.region.version>1.5.800</equinox.region.version>
         <equinox.coordinator.version>1.5.500</equinox.coordinator.version>
 

Reply via email to