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.
A number of provide/require/need/recommend dependencies are in fact on module code name bases, but the providing module is forced to redundantly declare OpenIDE-Module-Provides: $myowncnb This is annoying, and impossible in the case of a third-party OSGi bundle. It would be preferable if the module system considered every module to provide its own CNB automatically, so you could declare a require/need/recommend dep on it without any special work. As part of such a change, the redundant provide declaration should be removed from modules using it now: debugger.jpda.ui, etc.
Possible, we should probably do it only for new modules. E.g. use ModuleFormat2.
Integrated into 'main-golden' Changeset: http://hg.netbeans.org/main-golden/rev/38c68cb2fc7a User: Jesse Glick <jglick@netbeans.org> Log: CNBs and tokens were getting confused. Until #201695 is implemented, these are considered unrelated by the module system. Note that recommend clauses in java.kit and keyring are accordingly wrong.
Created attachment 118354 [details] Diff with API changes and their usage in OSGi mode
Created attachment 118457 [details] Diff with API changes, test, versioning and usage in core.netigso
I'll integrate on Friday.
ergonomics#21aa64230b67
<class package="org.openide.modules" name="ModuleInfo"/> should be removed since no change to this class's signature was made. A bunch of things ought to be updated to match this change: - org.netbeans.nbbuild.ModuleDependencies - org.netbeans.modules.apisupport.project.api.ManifestManager - all existing modules explicitly providing their own CNB should have this declaration removed, and all requirers should be modified to ask for "cnb.whatever" syntax Please either fix these, or file subissues and assign to me. I will tweak org.netbeans.core.osgi.Activator now since that overlaps with bug #210325, and it can be done before 21aa64230b67 has propagated.
Integrated into 'main-golden', will be available in build *201204250400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/16072c5a1db7 User: Jesse Glick <jglick@netbeans.org> Log: Using "cnb." prefix for module CNB pseudotokens for consistency with #201695.
(In reply to comment #7) > <class package="org.openide.modules" name="ModuleInfo"/> should be removed > since no change to this class's signature was made. The behavior of getProvides() method was changed. Imho, that warrants the link to ModuleInfo. I can add some additional info to javadoc if needed. > A bunch of things ought to be updated to match this change: > > - org.netbeans.nbbuild.ModuleDependencies Do you mean? # This patch file was generated by NetBeans IDE # It uses platform neutral UTF-8 encoding and \n newlines. --- Base (BASE) +++ Locally Modified (Based On LOCAL) @@ -240,6 +240,7 @@ addDependencies (depends, file.getManifest (), Dependency.Type.RECOMMENDS, "OpenIDE-Module-Recommends"); addDependencies (provides, file.getManifest (), /*irrelevant*/Dependency.Type.REQUIRES, "OpenIDE-Module-Provides"); { + provides.add(new Dependency("cnb." + module, Dependency.Type.REQUIRES, false, null)); String ideDeps = file.getManifest ().getMainAttributes ().getValue ("OpenIDE-Module-IDE-Dependencies"); // IDE/1 > 4.25 if (ideDeps != null) { throw new BuildException("OpenIDE-Module-IDE-Dependencies is obsolete in " + f); or something else? > - org.netbeans.modules.apisupport.project.api.ManifestManager ergonomics#527ee9fcfac4 > - all existing modules explicitly providing their own CNB should have this > declaration removed, and all requirers should be modified to ask for > "cnb.whatever" syntax I am not that sure. Changing the set of provided tokens might be an incompatible change. But for sure, people can now depend on cnb.* tokens.
Integrated into 'main-golden', will be available in build *201204260400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/21aa64230b67 User: Jaroslav Tulach <jtulach@netbeans.org> Log: #201695: Implicitly provide code name base token. #206365: Mimic OSGi dependencies with recommends/provides
Integrated into 'main-golden', will be available in build *201204270400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/527ee9fcfac4 User: Jaroslav Tulach <jtulach@netbeans.org> Log: #201695: Imply cnb. token
Is ergonomics#527ee9fcfac4 enough?