Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install Cobigen plugins into eclipse #84

Closed
hohwille opened this issue Apr 5, 2019 · 29 comments
Closed

Install Cobigen plugins into eclipse #84

hohwille opened this issue Apr 5, 2019 · 29 comments
Assignees
Labels
blocker severe bug that blocks users in their daily work and has to be fixed asap eclipse related to Eclipse IDE enhancement New feature or request help wanted Extra attention is needed scripts related to shell scripts (bash and CMD)
Milestone

Comments

@hohwille
Copy link
Member

hohwille commented Apr 5, 2019

We need to integrate cobigen as a plugin for Eclipse. Therefore all we need is a public update site URL and the feature id:
https://github.com/devonfw/devon-ide/blob/8a8c4a661d81e325260fd6c44423bfdb07f64b74/scripts/src/main/resources/scripts/command/eclipse#L106

@hohwille hohwille added enhancement New feature or request help wanted Extra attention is needed scripts related to shell scripts (bash and CMD) eclipse related to Eclipse IDE labels Apr 5, 2019
@hohwille hohwille added this to the release:3.0.0 milestone Apr 5, 2019
@hohwille hohwille added the blocker severe bug that blocks users in their daily work and has to be fixed asap label Apr 5, 2019
@maybeec maybeec assigned jdiazgon and unassigned jajimene Apr 9, 2019
@hohwille
Copy link
Member Author

hohwille commented Jun 5, 2019

@maybeec / @jdiazgon any progress, any milestone, any feedback?
Seems I have to release 3.0.0 without CobiGen integration.

@hohwille hohwille reopened this Jun 5, 2019
@hohwille
Copy link
Member Author

hohwille commented Jun 5, 2019

BTW: This was accidentally closed due to a bug in githubs autoclose feature.

@hohwille
Copy link
Member Author

@hohwille
Copy link
Member Author

There is only one valid plugin available from the update site with ID com.devonfw.cobigen.eclipse.feature.feature.group. The duplicated feature was already presented earlier. However, all the other plugins (com.devonfw.cobigen.tempeng-freemarker, etc. can not be found).

@hohwille
Copy link
Member Author

Advanced health check then gives me this error:
Screenshot 2019-07-29 at 14 26 49

@hohwille
Copy link
Member Author

Generation gives me this error:
Screenshot 2019-07-29 at 14 29 28

hohwille added a commit that referenced this issue Jul 29, 2019
* #145: improved verification of eclipse installation
* #145: fixed/improved installation to auto-detect if archive has a single top-level folder (except macos *.app dir) to omit in installation dir
* #84: install CobiGen from public update site
* #89: fixed another invisible unicode space character
* #148: updated vscode to 1.36.1
* #145: fixed proper download URL for vscode on windows to prevent broken ZIP download issue
* #145: fixed node installation verification to work also on windows
* #150: fixed m2e lifecylce-mapping config
* #149: prevent eclipse lock stopping to launch other IDEs
@hohwille
Copy link
Member Author

Technically implemented with PR #148
However, we have to analyse what is wrong with the update site and ensure we have all feature IDs included in eclipse commandlet of this IDE.

@maybeec
Copy link
Member

maybeec commented Aug 5, 2019

@hohwille I did not change anything, but installation was no problem for me at all.
All plugins were available, all plugins could be installed, sample generation works without error.
I took the latest devonfw ide as a reference, uninstalling all cobigen related plugins and reinstalling them from the new update site.

Let's have a chat if you are available.

@nricheton
Copy link

Hello,

I can confirm the JAXB error, when installing eclipse & Cobigen with devon-ide scripts.

@maybeec : since this looks like a dependency error, you have to start from a fresh eclipse install to see the problem.

Uninstalling from a working install probably keep the dependency installed.

Nicolas

@maybeec
Copy link
Member

maybeec commented Aug 14, 2019

@nricheton I just tried it with a fresh eclipse version downloaded from the eclipse public pages and installed cobigen. No problem. So I am wondering now how to reproduce this issue. What exactly did you do? What did you install, what didn't you install?

@nricheton
Copy link

nricheton commented Aug 14, 2019

I used devon-ide scripts 3.0.0 beta 11 (latest) to do the full environment setup on mac
=> Install succeed but I get the jab error when I do the advanced health check.

@maybeec
Copy link
Member

maybeec commented Aug 14, 2019

ok, I drilled it down. It seems to be an issue with jdk 11. I created a new issue in the cobigen repository regarding that: devonfw/cobigen#970

@hohwille
Copy link
Member Author

@nricheton and @maybeec 👍 for your analysis and taking this further.
So IMHO we need to get CobiGen fixed, create a new release, push this out to update site and then retest.
What about the plugins meanwhile? I removed all the plugin IDs except the core one in devon-ide as otherwise I was getting more errors. Is that correct and CobiGen is more monolytic now or is there still some other issue to solve?

https://github.com/devonfw/devon-ide/blob/3b098ce7188a137e7a1bd8a45455f4f10280c2f5/scripts/src/main/resources/scripts/command/eclipse#L117

@maybeec
Copy link
Member

maybeec commented Aug 19, 2019

So IMHO we need to get CobiGen fixed, create a new release, push this out to update site and then retest.

I will keep you posted.

What about the plugins meanwhile? I removed all the plugin IDs except the core one in devon-ide as otherwise I was getting more errors. Is that correct and CobiGen is more monolytic now or is there still some other issue to solve?

I will check about the issue and if there is some. But IMHO we should install all plug-ins by default. CobiGen is not yet able to lazily install plug-ins and as we actually don't know in which context the user is trying to make use of CobiGen, we have to be prepared as otherwise everyone will simply quit saying "it does not work".

@hohwille
Copy link
Member Author

My intention was always to install CobiGen completely with all plugins, so I fully agree @maybeec.
However, the update site I got was not able to resolve these plugin IDs that I got from an earlier manual installation and prepared in the commandlet.
Maybe also the IDs have changed. I will then already read them locally and try again...

@hohwille
Copy link
Member Author

OK, tried it and got the same error again:

devon eclipse add-plugin cobigen
Installing eclipse plugin com.devonfw.cobigen.eclipse.feature from https://dl.bintray.com/devonfw/cobigen.p2/
org.eclipse.m2e.logback.configuration: The org.eclipse.m2e.logback.configuration bundle was activated before the state location was initialized.  Will retry after the state location is initialized.
log4j:WARN No appenders could be found for logger (org.apache.http.client.protocol.RequestAddCookies).
log4j:WARN Please initialize the log4j system properly.
Installation failed.
The installable unit com.devonfw.cobigen.tsplugin.com.devonfw.cobigen.tempeng-velocity has not been found.
There were errors. See log file: /projects/software/default/eclipse/2019-06/Eclipse.app/Contents/Eclipse/configuration/1566325705342.log

******** ATTENTION ********
WARNING: Installation of plugin com.devonfw.cobigen.eclipse.feature failed. Please try to install manually.

➜  devon cat /projects/software/default/eclipse/2019-06/Eclipse.app/Contents/Eclipse/configuration/1566325705342.log
!SESSION 2019-08-20 20:28:25.242 -----------------------------------------------
eclipse.buildId=4.12.0.I20190605-1800
java.version=11.0.4
java.vendor=AdoptOpenJDK
BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_DE
Framework arguments:  -product org.eclipse.epp.package.java.product -application org.eclipse.equinox.p2.director -repository https://dl.bintray.com/devonfw/cobigen.p2/ -installIU com.devonfw.cobigen.eclipse.feature.feature.group,com.devonfw.cobigen.tempeng-freemarker,com.devonfw.cobigen.htmlplugin,com.devonfw.cobigen.javaplugin,com.devonfw.cobigen.jsonplugin,com.devonfw.cobigen.openapiplugin,com.devonfw.cobigen.propertyplugin,com.devonfw.cobigen.textmerger,com.devonfw.cobigen.tsplugin.com.devonfw.cobigen.tempeng-velocity,com.devonfw.cobigen.xmlplugin
Command-line arguments:  -os macosx -ws cocoa -arch x86_64 -product org.eclipse.epp.package.java.product -application org.eclipse.equinox.p2.director -repository https://dl.bintray.com/devonfw/cobigen.p2/ -installIU com.devonfw.cobigen.eclipse.feature.feature.group,com.devonfw.cobigen.tempeng-freemarker,com.devonfw.cobigen.htmlplugin,com.devonfw.cobigen.javaplugin,com.devonfw.cobigen.jsonplugin,com.devonfw.cobigen.openapiplugin,com.devonfw.cobigen.propertyplugin,com.devonfw.cobigen.textmerger,com.devonfw.cobigen.tsplugin.com.devonfw.cobigen.tempeng-velocity,com.devonfw.cobigen.xmlplugin

!ENTRY org.eclipse.equinox.p2.director.app 4 0 2019-08-20 20:28:29.045
!MESSAGE The installable unit com.devonfw.cobigen.tsplugin.com.devonfw.cobigen.tempeng-velocity has not been found.

@hohwille
Copy link
Member Author

OK. Obviously an invalid ID. It may have changed but it is more likely I did some copy&past bug as this does not make any sense:

com.devonfw.cobigen.tsplugin.com.devonfw.cobigen.tempeng-velocity

Do you know the correct ID for temeng-velocity before I find it?

@hohwille
Copy link
Member Author

@hohwille
Copy link
Member Author

It was just a . that needs to be a , in tsplugin.com.

hohwille added a commit that referenced this issue Aug 20, 2019
#84: fixed cobigen plugin IDs
#190: upgrade support from oasp4j-ide
#196: fixed prerequisites in documentation
#204: fixed eclipse startup script for MacOS
@hohwille
Copy link
Member Author

Merged PR #205
AFAIK all left to be done is creating a new CobiGen release working with Java11 and updating the update site on bintray.
So technically all is already done in this code-base if everything works as planned.

@hohwille hohwille mentioned this issue Aug 30, 2019
3 tasks
@hohwille
Copy link
Member Author

Requires this issue to be fixed:
devonfw/cobigen#970
and a release to be pushed out.

Do we have a critical path here?

@jdiazgon
Copy link
Member

Do we have a critical path here?

I'm currently working on it. The CobiGen CLI is > JDK9 compatible, but now I'm fixing CobiGen for Eclipse with > JDK9

@hohwille
Copy link
Member Author

hohwille commented Nov 4, 2019

I have already tested the lastest state and it works like a charm. Great job CobiGen team 👍

@Jan-PeterRichterCG
Copy link
Member

Jan-PeterRichterCG commented Dec 31, 2019

@hohwille, @maybeec, @jdiazgon: I just ran into apparently the same problem, although I am using devonfw-ide release 3.2.4-SNAPSHOT as of December, 21st.
I am also using Java 11:
openjdk version "11.0.5" 2019-10-15
OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.5+10)
OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.5+10, mixed mode)

The problem occured first during the setup of the ide. After firs setup, the eclipse installation is not attempted a second time ("already installed"), so I tried "devon eclipse add-plugin".

C:\projects\cashplanner3>devon eclipse add-plugin cobigen
Installing eclipse plugin com.devonfw.cobigen.eclipse.feature from https://dl.bintray.com/devonfw/cobigen.p2/

******** ATTENTION ********
WARNING: Installation of plugin com.devonfw.cobigen.eclipse.feature failed. Please try to install manually.

Threre is no further error message on the command line
Is there anything like an error log, so that I can try to find out more?

@Jan-PeterRichterCG
Copy link
Member

Jan-PeterRichterCG commented Dec 31, 2019

OK, I just found a log file:

!SESSION` 2019-12-31 17:24:36.790 -----------------------------------------------
eclipse.buildId=4.13.0.I20190916-1045
java.version=11.0.5
java.vendor=AdoptOpenJDK
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.java.product -application org.eclipse.equinox.p2.director -repository https://dl.bintray.com/devonfw/cobigen.p2/ -installIU com.devonfw.cobigen.eclipse.feature.feature.group,com.devonfw.cobigen.tempeng-freemarker,com.devonfw.cobigen.htmlplugin,com.devonfw.cobigen.javaplugin,com.devonfw.cobigen.jsonplugin,com.devonfw.cobigen.openapiplugin,com.devonfw.cobigen.propertyplugin,com.devonfw.cobigen.textmerger,com.devonfw.cobigen.tsplugin,com.devonfw.cobigen.tempeng-velocity,com.devonfw.cobigen.xmlplugin
Command-line arguments:  -os win32 -ws win32 -arch x86_64 -product org.eclipse.epp.package.java.product -application org.eclipse.equinox.p2.director -repository https://dl.bintray.com/devonfw/cobigen.p2/ -installIU com.devonfw.cobigen.eclipse.feature.feature.group,com.devonfw.cobigen.tempeng-freemarker,com.devonfw.cobigen.htmlplugin,com.devonfw.cobigen.javaplugin,com.devonfw.cobigen.jsonplugin,com.devonfw.cobigen.openapiplugin,com.devonfw.cobigen.propertyplugin,com.devonfw.cobigen.textmerger,com.devonfw.cobigen.tsplugin,com.devonfw.cobigen.tempeng-velocity,com.devonfw.cobigen.xmlplugin

!ENTRY org.eclipse.equinox.p2.artifact.repository 4 1000 2019-12-31 17:24:41.949
!MESSAGE No repository found at https://dl.bintray.com/devonfw/cobigen.p2/.

!ENTRY org.eclipse.equinox.p2.metadata.repository 4 1000 2019-12-31 17:24:42.800
!MESSAGE No repository found at https://dl.bintray.com/devonfw/cobigen.p2/.

!ENTRY org.eclipse.equinox.p2.core 4 0 2019-12-31 17:24:42.806
!MESSAGE Unable to load repositories.

Where are the plugins?

OK, I found the section on manual installation of the CobiGen Eclipse integration on Section X, chapter 54 of the devonfw guide. It refers to http://de-mucevolve02/files/cobigen/updatesite/stable/ which is accessible for Capgemini staff only. Also, the instructions on what to install are not very precise: The commandlet installs com.devonfw.cobigen.eclipse.feature.feature.group,com.devonfw.cobigen.tempeng-freemarker,com.devonfw.cobigen.htmlplugin,com.devonfw.cobigen.javaplugin,com.devonfw.cobigen.jsonplugin,com.devonfw.cobigen.openapiplugin,com.devonfw.cobigen.propertyplugin,com.devonfw.cobigen.textmerger,com.devonfw.cobigen.tsplugin,com.devonfw.cobigen.tempeng-velocity,com.devonfw.cobigen.xmlplugin (but you see this only if you look into the commandlet code or if you find the log file). The screenshot in the guide has only two ticks: FreeMarker Template Engine and Java Plugin.

@Jan-PeterRichterCG
Copy link
Member

Hmmmm... now I am stuck with the next problem: The guide says: "Checkout (clone) your project’s templates folder or use the current templates released with
CobiGen (https://github.com/devonfw/tools-cobigen/tree/master/cobigen-templates) and [...]" However, I cannot git clone https://github.com/devonfw/tools-cobigen/tree/master/cobigen-templates ("fatal: repository 'https://github.com/devonfw/tools-cobigen/tree/master/cobigen-templates/' not found") I can also not clone the complete repository due to excessively long paths and file names that are not supported unter Windows..

What can I do?

@markusschuh
Copy link
Member

A hint on your last point about the issues with long paths:

git is able to use the newer Windows API - without that limitation - when needed, since longer. But you need to activate this with help of the following config setting

git config --system core.longpaths true

Besides that you could also download each github repository as ZIP archive (check the web gui on main directory of repo for that option) and such extract only those dirs/files to filesystem, you need.

@markusschuh
Copy link
Member

Also it might be good to open this as an own issue, since this issue was (mostly) about the former JDK 11 incompatibility.
The current issue seems just to be some coordination mix-up: the devonfw-ide has already started referig the bintray repository for cobigen-eclipse-plugin installation - but this repo does not seem to have any released files yet, (see https://bintray.com/devonfw/cobigen.p2 )

@maybeec
Copy link
Member

maybeec commented Jan 3, 2020

@Jan-PeterRichterCG , @markusschuh , as of discussions with legal regarding public distribution of packaged solutions like CobiGen eclipse installation bundles, we needed to take them offline.
Now we are currently in the process to redistribute them by assuring correct licensing texts shipped with the bundles.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocker severe bug that blocks users in their daily work and has to be fixed asap eclipse related to Eclipse IDE enhancement New feature or request help wanted Extra attention is needed scripts related to shell scripts (bash and CMD)
Projects
None yet
Development

No branches or pull requests

7 participants