This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 519716 - Move org.eclipse.jst.common.ui from common to jeetools
Summary: Move org.eclipse.jst.common.ui from common to jeetools
Status: RESOLVED FIXED
Alias: None
Product: WTP Java EE Tools
Classification: WebTools
Component: jst.j2ee (show other bugs)
Version: 3.10   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 3.10 M3   Edit
Assignee: jst.j2ee CLA
QA Contact: Chuck Bridgham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 525342
  Show dependency tree
 
Reported: 2017-07-14 15:38 EDT by Rob Stryker CLA
Modified: 2017-11-16 12:58 EST (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rob Stryker CLA 2017-07-14 15:38:41 EDT
The plugin org.eclipse.jst.common.ui is in common repo, depends on org.eclipse.jst.common.frameworks, and causes circular dependencies between components. 

1) Verify no plugin / feature / test in common depends on org.eclipse.jst.common.ui

    cd webtools.common;grep -R "jst.common.ui" * | grep -v "^plugins/org.eclipse.jst.common.ui" | grep -v "Binary file"

   This result is empty. 

2) Since jeetools (destination) is higher in the chain, verify no plugins in server / sourceediting / jsdt depend on org.eclipse.jst.common.ui

[rob@rawbdorable webtools.javaee] (master)$ cd ../webtools.servertools
[rob@rawbdorable webtools.servertools] (master)$ grep -R "jst.common.ui" * | grep -v "^plugins/org.eclipse.jst.common.ui" | grep -v "Binary file"
[rob@rawbdorable webtools.servertools] (master)$ cd ../webtools.jsdt/
[rob@rawbdorable webtools.jsdt] (master)$ grep -R "jst.common.ui" * | grep -v "^plugins/org.eclipse.jst.common.ui" | grep -v "Binary file"
[rob@rawbdorable webtools.jsdt] (master)$ cd ../webtools.sourceediting
[rob@rawbdorable webtools.sourceediting] (master)$ grep -R "jst.common.ui" * | grep -v "^plugins/org.eclipse.jst.common.ui" | grep -v "Binary file"
[rob@rawbdorable webtools.sourceediting] (master)$ 


3) Check that something in jeetools already depends on this plugin and that it fits best here.

[rob@rawbdorable webtools.javaee] (master)$ cd ../webtools.javaee
[rob@rawbdorable webtools.javaee] (master)$ grep -R "jst.common.ui" * | grep -v "^plugins/org.eclipse.jst.common.ui" | grep -v "Binary file" | wc -l
13

4) Check that a feature in javaee actually includes this plugin:

[rob@rawbdorable webtools.javaee] (master)$ cd features; grep -R "jst.common.ui" * | grep -v "^plugins/org.eclipse.jst.common.ui" | grep -v "Binary file"  | grep -v "target"
org.eclipse.jst.web_ui.feature/feature.xml:         id="org.eclipse.jst.common.ui"

5) Summary:
   No component below jeetools depends on this plugin  (common, server, sourceediting, jsdt)
   It is included by a jeetools feature
   It is depended on by jeetools plugins
   
6) Conclusion: It fits best in jeetools, and is safe to move. Moving this will not change any API.
Comment 1 Rob Stryker CLA 2017-07-14 15:39:37 EDT
Best way to move a plugin and preserve history:

http://gbayer.com/development/moving-files-from-one-git-repository-to-another-preserving-history/
Comment 2 Rob Stryker CLA 2017-07-17 14:13:02 EDT
Gist script to move the plugin into javaee.   

https://gist.github.com/robstryker/e4856a8ef28d8673664e4e2759f21524

Once this script is executed and pushed, the plugin can be removed from common and common's pom.xml.
Comment 3 Rob Stryker CLA 2017-07-20 18:03:21 EDT
I tried running the script and pushing to refs/for/master (ie gerrit review) and it was rejected with the following message:

remote: Resolving deltas: 100% (238/238)
remote: Processing changes: refs: 1, done    
remote: 
remote: ERROR:  In commit d41553f5c5d836d6b8598c480b1d7122deadc418
remote: ERROR:  committer email address cbridgha
remote: ERROR:  does not match your user account.
remote: ERROR:
remote: ERROR:  The following addresses are currently registered:
remote: ERROR:    stryker@redhat.com
remote: ERROR:
remote: ERROR:  To register an email address, please visit:
remote: ERROR:  https://git.eclipse.org/r/#/settings/contact
remote: 
remote: 


Basically, bringing a full plugin over with history seems to require some more permissions unless you were the only one who ever touched that plugin.
Comment 4 Nick Boldt CLA 2017-09-28 11:36:15 EDT
As of 5 mins ago, webtools.common can't be built independently because of this error:

[ERROR] Cannot resolve project dependencies:
[ERROR]   Software being installed: org.eclipse.jst.common.ui 1.0.301.qualifier
[ERROR]   Missing requirement: org.eclipse.jst.common.ui 1.0.301.qualifier requires 'bundle org.eclipse.jst.common.frameworks 1.1.400' but it could not be found

So... once that plugin is moved down to another repo, we should be good here, and I can get the first of the cascaded builds running on eclipse.org

Work in progress here: https://hudson.eclipse.org/webtools/job/webtools-common_R3_10/
Comment 5 Nick Boldt CLA 2017-10-12 12:35:06 EDT
Any chance we can get this script run and this plugin moved to another repo, so I can remove my sed hack from the build [1]?

   # comment out the jst.common.ui plugin as it's scheduled to move to the javaee repo - https://bugs.eclipse.org/bugs/show_bug.cgi?id=519716
   sed -i -e "s#\(.\+\)\(<module>org.eclipse.jst.common.ui</module>\)#\1<!-- \2 -->#" plugins/pom.xml

[1] https://hudson.eclipse.org/webtools/job/webtools-common_R3_10/configure
Comment 6 Rob Stryker CLA 2017-10-12 14:24:48 EDT
@Chuck:  Please +1 this issue if you think I've done the proper amount of due-diligence. 


Comment from Elson, who just did a repository merge: 

Repo merged in master.

For future reference, when merging repos, the follow needs to be done to bypass Gerrit reviews and also prevent error for pushing commits done by other users:
1. disable IP check (web master)
2. forge author (already on by default)
3. grant forge committer (web master)
4. grant forge server (web master)
5. push changes to refs/heads/*, e.g. HEAD:refs/heads/master
Comment 7 Chuck Bridgham CLA 2017-10-12 15:11:24 EDT
+1 I'm fine with this...

Thanks
Comment 8 Nick Boldt CLA 2017-10-12 15:24:52 EDT
@webmaster:

With Chuck's approval, can you perform the move of the one plugin from common to jeetools?

https://gist.github.com/robstryker/e4856a8ef28d8673664e4e2759f21524

Thanks!
Comment 9 Rob Stryker CLA 2017-10-17 18:37:48 EDT
This has been pushed to master / photon today. I'm really not sure what 'target milestone' that represents, though.  :|
Comment 10 Eclipse Genie CLA 2017-10-20 04:14:58 EDT
New Gerrit change created: https://git.eclipse.org/r/110425
Comment 11 Nick Boldt CLA 2017-10-21 04:05:05 EDT
Reopen so that Chuck, Carl, or anyone with push rights to webtools.javaee can push my fix so that the webtools.releng.aggregator uberbuild works again. 

https://git.eclipse.org/r/110425
Comment 13 Chuck Bridgham CLA 2017-11-16 12:58:52 EST
This should be closed now