This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Alternative Bundle-SymbolicName for NetBeans modules | ||
---|---|---|---|
Product: | platform | Reporter: | Jaroslav Tulach <jtulach> |
Component: | Netigso | Assignee: | Jesse Glick <jglick> |
Status: | RESOLVED WONTFIX | ||
Severity: | normal | CC: | jglick, jtulach |
Priority: | P3 | ||
Version: | 7.0.1 | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | ENHANCEMENT | Exception Reporter: | |
Bug Depends on: | |||
Bug Blocks: | 197842 |
Description
Jaroslav Tulach
2011-04-20 14:16:24 UTC
Would seem to be simpler to just specify the actual OSGi tags in the JAR manifest, e.g.: OpenIDE-Module: org.netbeans.libs.jsch/1 OpenIDE-Module-Specification-Version: 1.17 Bundle-SymbolicName: com.jcraft.jsch Bundle-Version: 0.1.43 The NB module system will use OpenIDE-Module* preferentially, whereas the OSGi container will only pay attention to Bundle-*. (In reply to comment #1) > Would seem to be simpler to just specify the actual OSGi tags in the JAR > manifest, e.g.: That would be misleading. > The NB module system will use OpenIDE-Module* preferentially, whereas the OSGi > container will only pay attention to Bundle-*. As the JARs are not proper OSGi bundles and the runtime would treat them like that. Such JARs can only be executed in Netigso and thus it makes more sense to use Netigso specific tag. (In reply to comment #2) > the JARs are not proper OSGi bundles True, because (external) Class-Path is not supported by OSGi. Obviously Netigso.fakeBundle would need to be modified. The tricky part is that the netigso:// URL is used in several places with the assumption that the host part is both a NB CNB and an OSGi BSN: Netigso.fakeOneModule, Netigso.toActivate, and NetigsoActivator.get. I think the best fix is to treat the host part as a BSN; then toActivate requires no change, fakeOneModule just needs to check for the variant attr, and get needs to do the same. I can try to do the changes in a branch. Might take a little work to understand how to write a unit test for it. OK, if you wish. Unit tests are as easy as the ones for regular ModuleManager. Committed to a branch: core-main #34830f9b9da8 Backed it out; not usable. Integrated into 'main-golden' Changeset: http://hg.netbeans.org/main-golden/rev/34830f9b9da8 User: Jesse Glick <jglick@netbeans.org> Log: #197908: permit a module to declare an alternate BSN and/or version when considered as a bundle. |