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: | hudson plugin won't deactivate | ||
---|---|---|---|
Product: | php | Reporter: | BullfrogBlues |
Component: | Code | Assignee: | Tomas Mysik <tmysik> |
Status: | VERIFIED FIXED | ||
Severity: | normal | CC: | alibaba88, jglick, jrechtacek, jtulach, kanakmar, liono, mmirilovic, pjiricka, tmysik |
Priority: | P2 | ||
Version: | 7.2 | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: | |
Bug Depends on: | |||
Bug Blocks: | 211562 | ||
Attachments: | Yet another is.eager approach |
Description
BullfrogBlues
2012-07-25 21:38:56 UTC
*** Bug 218159 has been marked as a duplicate of this bug. *** I think this is pretty serious -> P2. *** Bug 217056 has been marked as a duplicate of this bug. *** *** Bug 211562 has been marked as a duplicate of this bug. *** *** Bug 219303 has been marked as a duplicate of this bug. *** *** Bug 209999 has been marked as a duplicate of this bug. *** The case of hudson is as follows: php.kit recommends hudson.php and that one depends on hudson. Because php.kit remains enabled, it tried to turn hudson.php up and that in turn re-enabled hudson. Just make hudson.php an eager module and remove the recommends from the kit. diff -r ccd07a11e690 hudson.php/nbproject/project.properties --- a/hudson.php/nbproject/project.properties Wed Nov 07 03:49:32 2012 +0100 +++ b/hudson.php/nbproject/project.properties Wed Nov 07 10:44:33 2012 +0100 @@ -1,4 +1,4 @@ -is.autoload=true +is.eager=true javac.source=1.6 javac.compilerargs=-Xlint -Xlint:-serial release.external/config-4f37f781e487dc957ff09359d8a5cb51e6588ff9.xml=hudson/config.xml diff -r ccd07a11e690 php.kit/manifest.mf --- a/php.kit/manifest.mf Wed Nov 07 03:49:32 2012 +0100 +++ b/php.kit/manifest.mf Wed Nov 07 10:44:33 2012 +0100 @@ -2,4 +2,4 @@ OpenIDE-Module: org.netbeans.modules.php.kit OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/php/kit/Bundle.properties OpenIDE-Module-Specification-Version: 1.47 -OpenIDE-Module-Recommends: cnb.org.netbeans.modules.hudson.php, cnb.org.netbeans.modules.languages.ini, cnb.org.netbeans.modules.languages.neon, cnb.org.netbeans.modules.php.apigen, cnb.org.netbeans.modules.web.clientproject, cnb.org.netbeans.modules.websvc.saas.codegen.php, cnb.org.netbeans.modules.websvc.saas.kit +OpenIDE-Module-Recommends: cnb.org.netbeans.modules.languages.ini, cnb.org.netbeans.modules.languages.neon, cnb.org.netbeans.modules.php.apigen, cnb.org.netbeans.modules.web.clientproject, cnb.org.netbeans.modules.websvc.saas.codegen.php, cnb.org.netbeans.modules.websvc.saas.kit I will do that, thanks for the patch. But I have to say that I am now a bit confused whether recommended modules work... (I expect the same for WS etc.). Thanks. Also, this patch can hardly fix e.g. issue #209999 which is marked as a duplicate of this issue... (In reply to comment #9) > Also, this patch can hardly fix e.g. issue #209999 which is marked as a > duplicate of this issue... I was hoping to fix this in the infrastructure, but I am not able to find a way to do it. I will have to re-open the other bugs. (In reply to comment #8) > I will do that, thanks for the patch. But I have to say that I am now a bit > confused whether recommended modules work... (I expect the same for WS etc.). Seems to me that recommending a module with UI or an element in the Plugins list is wrong. The hudson case seems like a clear "bridge case" - e.g. a module that depends on other functionalities and should be enabled whenever they are both enabled. For this purpose eager is ideal. I am not sure about the other cases. (In reply to comment #10) > Seems to me that recommending a module with UI or an element in the Plugins > list is wrong. Interesting since to me, it makes perfect sense to recommend plugin from Plugins list, e.g. if there is a plugin for some templates (which can be used standalone) and there is some framework which can use these templates (or any others) - the framework could recommend this templates plugin and it is up to user to decide [1] whether he wants it or not. Thanks for your explanation. [1] I know that we have no UI for recommended modules yet. Fixed the hudson and php part - thanks again Jardo for the patch. I will reopen the duplicates. http://hg.netbeans.org/web-main/rev/1f116f69a44b I am sorry but I have to reopen this issue since I had to rollback [1] the fix - the commit validation failed for our team build [2]. Jardo, could you please check the test failure if it is correct or not? Thanks a lot. [1] http://hg.netbeans.org/web-main/rev/00e74f3b56ea [2] http://bertram2.netbeans.org:8080/job/web-main/9152/ (In reply to comment #11) > I know that we have no UI for recommended modules yet. Such a user-level feature cannot be implemented using this module system facility; it was never designed for it. You would need to introduce new metadata interpreted by Plugin Manager. Integrated into 'main-golden', will be available in build *201211090001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/1f116f69a44b User: Tomas Mysik <tmysik@netbeans.org> Log: #215972 - hudson plugin won't deactivate I've reapplied 1f116f69a44b locally, rebuilt php.kit and hudson.php and ide.ergonomics, but running following command seems to work OK: $ ant -f ide.ergonomics/build.xml test-single -Dtest.includes=**/Caching* -do-junit-single: [junit] Testsuite: org.netbeans.modules.ide.ergonomics.CachingPreventsLoadingOfModuleManifestsTest [junit] System class loader patches: /home/jarda/src/netbeans/ergonomics/ide.ergonomics/build/test/unit/classes [junit] System class loader patches: /home/jarda/src/netbeans/ergonomics/ide.ergonomics/build/test/unit/classes [junit] Tests run: 4, Failures: 0, Errors: 0, Time elapsed: 26,57 sec I'll try to do clean build now. $ ant clean build commit-validation reproduces the problem. Created attachment 127498 [details]
Yet another is.eager approach
It turns out that the hudson.php module does not depend on any regular module from php cluster. Only two autoload APIs. The current behavior is to turn such eager module on anyway which is not what we want and the failing test detected that correctly.
Possible solution is to add dependency on some regular module from php cluster. My patch tries that with php.kit. It is sort of artificial, but it seems to behave well in the IDE.
Maybe there is a better regular (usually means with user visible UI) module in the php cluster to depend on...
I had some additional changes locally, but I hope they don't affect the previous conclusion. Passing to Tomáš to polish the changes to suite his needs. Should be fixed now, Martine please verify, Thanks. http://hg.netbeans.org/web-main/rev/a7beea41783b Integrated into 'main-golden', will be available in build *201211140001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/a7beea41783b User: Tomas Mysik <tmysik@netbeans.org> Log: #215972 - hudson plugin won't deactivate After applying the "Yet another is.eager approach" patch, hudson.php unit tests started to fail - see [1]. Jardo, could you please have a look at it (I tried it but no success, sorry!)? I really don't see any connection with your patch but the tests are fixed again once I revert it... Reopening and assigning to Jarda, please, reassign back once you know the cause. Thanks a lot. [1] http://bertram.netbeans.org:8080/job/PHP-build/5648/testReport/junit/org.netbeans.modules.hudson.php.xml/XmlUtilsTest/testAsString/ Looks like php.kit has an (indirect) dependency on a module that provides non-functional part of XML parser. One fix may be to change the dependencies (so the JAR file is not on classpath of the test). Or I think there is a way to specify the preferred XML parser using a property - the test could set it before its execution. The proper fix however would be to remove the non-functional XML parser module from the IDE. I don't really get why PHP support needs to bundle broken XML parser... (In reply to comment #23) > I don't really get why PHP support needs to bundle broken XML > parser... We parse e.g. XML file from PHPUnit. I will look at it. Closing back as FIXED, the test failure will be fixed in PHP area. Thanks. verified - Hudson plug-in is possible to deactivate Product Version: NetBeans IDE Dev (Build 201211150001) Java: 1.7.0_10-ea; Java HotSpot(TM) Client VM 23.6-b04 Runtime: Java(TM) SE Runtime Environment 1.7.0_10-ea-b15 |