Startup tasks not executed if project.setup is pulled from redirected setup [message #1741289] |
Wed, 24 August 2016 11:51 |
Simon Stratmann Messages: 10 Registered: August 2016 |
Junior Member |
|
|
Hi,
I have a project.setup file that contains some tasks for downloading and extratcing files and resource modification for bootstrapping and some tasks for eclipse workspace preferences, so startup tasks.
I redirect to a hosted org.eclipse.setup file that contains my setup.project file as "projectCatalog".
When I add the project.setup file in the advanced installer manually and install my project from that file everything is fine; at first startup the preferences are set and working sets are created.
If install using the hosted project.setup file that then none of the startup tasks are executed. The "Setup tasks" windows doesn't contain any of them. I'm 100% sure that the files are identical, I actually add them from my HTTP repository for the first test. So the only difference is how the installer accesses them. How is that possible?
setup.log from error case:
[2016-08-24 14:26:50] Performing post bootstrap tasks
[2016-08-24 14:26:50]
[2016-08-24 14:26:50] Launching the installed product...
(EOF)
setup.log from positive case:
[2016-08-24 14:07:41] Performing post bootstrap tasks
[2016-08-24 14:07:41]
[2016-08-24 14:07:41] Launching the installed product...
[2016-08-24 14:08:44] Executing startup tasks
[2016-08-24 14:08:45] Java(TM) SE Runtime Environment 1.8.0_60-b27
[2016-08-24 14:08:45] Product org.eclipse.products.epp.package.java.latest.released
... A lot more lines
[Updated on: Wed, 24 August 2016 12:28] Report message to a moderator
|
|
|
|
Re: Startup tasks not executed if project.setup is pulled from redirected setup [message #1741393 is a reply to message #1741385] |
Wed, 24 August 2016 16:52 |
Simon Stratmann Messages: 10 Registered: August 2016 |
Junior Member |
|
|
Hi Ed,
thanks for helping out. Tried using the redirection approach:
I added -Doomph.redirection.myProjectCatalog=index:/redirectable.projects.setup->http://werum2103:5001/my.projects.setup to eclipse.inst.ini
my.projects.setup looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<setup:ProjectCatalog
xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:setup="http://www.eclipse.org/oomph/setup/1.0"
xmlns:setup.targlets="http://www.eclipse.org/oomph/setup/targlets/1.0"
xsi:schemaLocation="http://www.eclipse.org/oomph/setup/targlets/1.0 http://git.eclipse.org/c/oomph/org.eclipse.oomph.git/plain/setups/models/SetupTarglets.ecore"
name="org.eclipse"
label="PAS-X SDK">
<project href="http://werum2103:5001/setups/PASSDKProject.setup#/"/>
<setupTask
xsi:type="setup:EclipseIniTask"
option="-Doomph.redirection.myProjectCatalog=index:/redirectable.projects.setup->http://werum2103:5001/my.projects.setup"
value=""/>
</setup:ProjectCatalog>
I won't add the content of the actual project setup file as it's quite long. But it contains the same Eclipse Ini Task for forwarding.
Now when I install that project then no startup tasks are executed at all. Adding that setup file manually and installing with that project the tasks are executed at startup.
I even tried downloading the Ooomph source code and hosting the whole setup folder and using that and it still didn't work.
[Updated on: Wed, 24 August 2016 16:53] Report message to a moderator
|
|
|
Re: Startup tasks not executed if project.setup is pulled from redirected setup [message #1741395 is a reply to message #1741393] |
Wed, 24 August 2016 17:06 |
Simon Stratmann Messages: 10 Registered: August 2016 |
Junior Member |
|
|
Also, for a test, I disabled the automatic start of eclipse after installing. I opened the eclipse.ini and added the same redirections and update sites as in eclipse-inst.ini:
-Doomph.installer.update.url=http://pasxnexus.werum.net/nexus/content/groups/pasx_sdk_update_group
-Doomph.update.url=http://pasxnexus.werum.net/nexus/content/groups/pasx_sdk_update_group
-Doomph.redirection.myProjectCatalog=index:/redirectable.projects.setup->http://werum2103:5001/my.projects.setup
I started Eclipse and no startup tasks were performed. I opened the Catalog Index and made sure that my Project was contained there.
The correctly installed Eclipse contains my project in the "Open Setup" context menu, the wrong installed Eclipse does not.
Is the name of the option ("-Doomph.redirection.whatever") relevant (the "whatever" part")?
[Updated on: Wed, 24 August 2016 18:16] Report message to a moderator
|
|
|
|
Re: Startup tasks not executed if project.setup is pulled from redirected setup [message #1741429 is a reply to message #1741413] |
Thu, 25 August 2016 05:47 |
Ed Merks Messages: 33258 Registered: July 2009 |
Senior Member |
|
|
Simon,
Is the project simply contained in the catalog, or is it in a separate resource that's cross resource contained by the catalog? If the latter, what does the URI look like? Is it an absolute URI?
Note that the projects are referenced by the workspace.setup. You can use Navigate -> Open Setup -> Workspace to open it. From the context menu of the setup editor, you can use Open Text Editor to look at the file textually. What does the URI for the reference to the project setup look like? I suspect in both cases the project reference is present, but in the incorrectly functioning case that it's an unresolved proxy. Hence the question about how the project catalog references or contains the project setup, and this followup question about how the reference look in the workspace.setup.
When using -Doomph.redirection.*, the * has no semantic significance, other than the fact that multiple Eclipse Ini tasks can be merged, so if there is more than one task for -Dxyz=abc and -Dxyz=def you'll end up with a single task, so definitely it's good to make the * part unique in your overall context.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Re: Startup tasks not executed if project.setup is pulled from redirected setup [message #1741440 is a reply to message #1741429] |
Thu, 25 August 2016 07:49 |
Simon Stratmann Messages: 10 Registered: August 2016 |
Junior Member |
|
|
Hi Ed,
the file my.projects.setup I quoted above (and which I redirect to) contains an absolute link to my project: <project href="http://werum2103:5001/setups/PASSDKProject.setup#/"/>
For the positive case my workspace.setup looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<setup:Workspace
xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:setup="http://www.eclipse.org/oomph/setup/1.0"
name="workspace">
<setupTask
xsi:type="setup:VariableTask"
name="eclipse.target.platform"
value="Neon"
defaultValue="Neon"
label="Target Platform">
<description>Choose the compatibility level of the target platform</description>
</setupTask>
<stream href="index:/org.eclipse.setup#//@projectCatalogs[name='org.eclipse']/@projects[name='user.project']/@projects[name='PAS-X%20SDK24']/@streams[name='master']"/>
</setup:Workspace>
For the one where it doesn't work it looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<setup:Workspace
xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI"
xmlns:setup="http://www.eclipse.org/oomph/setup/1.0"
name="workspace"/>
So it doesn't contain any mention of a setup task or my project. But user.setup actually contains an unresolved project. The warning displayed in the setup editor:
The feature 'restrictions' of ' PAS-X SDK24' contains an unresolved proxy ' index:/org.eclipse.setup#//@projectCatalogs[name='org.eclipse']/@projects[name='PAS-X%20SDK24']'
Content of the user.setup file:
<?xml version="1.0" encoding="UTF-8"?>
<setup:User
xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:setup="http://www.eclipse.org/oomph/setup/1.0"
name="Administrator"
unsignedPolicy="ACCEPT">
<setupTask
xsi:type="setup:CompoundTask"
name="PAS-X SDK Projects">
<restriction
xsi:type="setup:ProjectCatalog"
href="index:/org.eclipse.setup#//@projectCatalogs[name='org.eclipse']"/>
<setupTask
xsi:type="setup:CompoundTask"
name="PAS-X SDK24">
<restriction
xsi:type="setup:Project"
href="index:/org.eclipse.setup#//@projectCatalogs[name='org.eclipse']/@projects[name='PAS-X%20SDK24']"/>
<setupTask
xsi:type="setup:VariableTask"
name="sdk.id"
value="fromweb3"
label="Name of the SDK (determines installation folder and workspace name. No spaces!!!)"/>
<setupTask
xsi:type="setup:VariableTask"
name="install.root"
value="e:\Projects"
defaultValue="e:\Projects"/>
</setupTask>
</setupTask>
<acceptedLicense>DEFAULT_LICENSE Marker to remember license pre-prompting</acceptedLicense>
<acceptedLicense>6a3d083ad2bd7d3a80ee293235f8c5b1 Eclipse Foundation Software User Agreement</acceptedLicense>
<acceptedLicense>abc76a6cc9d06e4684ff61ed74a972c Eclipse Foundation Software User Agreement</acceptedLicense>
<acceptedLicense>731702f483d5de88d5a85543a649cb74 SPRING IDE PROJECT SOFTWARE USER AGREEMENT</acceptedLicense>
<acceptedLicense>2b495527b315808f459ac5454dbbe2da Eclipse Integration Commons 3.8.0 GA</acceptedLicense>
<acceptedLicense>aa1a84ed6378c1cdba13a100c225aa57 Eclipse Foundation Software User Agreement</acceptedLicense>
<acceptedLicense>b7a823f17bfa0073f4413c5638a30054 The TMate Open Source License</acceptedLicense>
<acceptedLicense>4420907242c49cfbbc1776eaa3ae7a79 Pivotal tc Sever Integration for Eclipse 3.8.0 GA</acceptedLicense>
<acceptedLicense>a4f11ab3cd6579b763157aa48441b3bc Subclipse Software User Agreement</acceptedLicense>
<acceptedLicense>3641c6b239e0abe8026299bd04d700e2 License Agreement for ZeroTurnaround Software</acceptedLicense>
<acceptedLicense>121140a2cbaa22d157099dd10a242d92 Eclipse Public License - v 1.0</acceptedLicense>
<acceptedLicense>30d252f582a9f4ebadd81c36d1b23c52 Eclipse Public License - v 1.0</acceptedLicense>
</setup:User>
So it seems indeed that something cannot be resolved but I have no idea what that could be or how to fix it.
Thanks for the help, I appreciate it.
Update: I also noticed that when using the manually added project the installer displays a selection box for the target platform, but not when using the redirected setup file.
[Updated on: Thu, 25 August 2016 16:05] Report message to a moderator
|
|
|
|
|
|
Re: Startup tasks not executed if project.setup is pulled from redirected setup [message #1775000 is a reply to message #1774999] |
Mon, 23 October 2017 11:31 |
Ed Merks Messages: 33258 Registered: July 2009 |
Senior Member |
|
|
Here's one from the Oomph.setup:<?xml version="1.0" encoding="UTF-8"?>
<setup:EclipseIniTask
xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI"
xmlns:setup="http://www.eclipse.org/oomph/setup/1.0"
option="-Doomph.redirection.setups"
value="=http://git.eclipse.org/c/oomph/org.eclipse.oomph.git/plain/setups/->${git.clone.oomph.location|uri}/setups/"
vm="true"/>
Note it's a VM option (not a program option), and that it does use -D to specify system property, and that the value specifically does include the "=".
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.04015 seconds