使用ECF实现远程OSGI:BNDRun文件缺失Bundle排查求助
Required Bundles for ECF Generic Remote Service in Bndrun
Got it, let's break down exactly which bundles you need in your bndrun file to get that ECF generic remote service up and running. Since you're using ecf.generic.server as your exported config, here's the essential list you should add:
Core Bundles You Can't Skip
org.osgi.service.remoteserviceadmin
This is the official OSGi Remote Service Admin API bundle—your code uses theservice.exported.interfacesandservice.exported.configsproperties defined by this spec, so it's non-negotiable.org.eclipse.ecf.core
The foundational ECF framework bundle, providing core remote communication APIs and infrastructure that all ECF providers rely on.org.eclipse.ecf.remoteservice
Implements the OSGi remote service specification on top of ECF core—handles the heavy lifting of exporting/importing services across the network.org.eclipse.ecf.provider.generic.server
The server-side implementation for ECF's generic remote service provider. This is directly tied to theecf.generic.serverconfig you're using in your props.
Optional but Recommended Bundles
org.eclipse.ecf.provider.generic
Contains shared components and client-side logic for the generic provider. Even if you're only setting up the server, including this avoids potential missing dependency errors.org.eclipse.equinox.concurrent
ECF uses this bundle for concurrency handling in some cases—adding it prevents runtime exceptions related to thread pool management.
Example Bndrun Configuration
You can add these directly to your -runbundles section like this:
-runbundles: \ org.osgi.service.remoteserviceadmin,\ org.eclipse.ecf.core,\ org.eclipse.ecf.remoteservice,\ org.eclipse.ecf.provider.generic,\ org.eclipse.ecf.provider.generic.server,\ org.eclipse.equinox.concurrent
Or use -runrequires to let bnd automatically resolve dependencies for you:
-runrequires: \ osgi.identity;filter:="(osgi.identity=org.eclipse.ecf.provider.generic.server)",\ osgi.identity;filter:="(osgi.identity=org.osgi.service.remoteserviceadmin)"
Just make sure your bnd workspace has access to the ECF and OSGi Remote Service Admin repositories so these bundles can be resolved.
内容的提问来源于stack exchange,提问作者Umesh Timalsina
相关产品推荐
相关产品推荐

