Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 278154

Summary: eclipse.ini has wrong splash screen
Product: [Technology] EPP Reporter: David Williams <david_williams>
Component: jee-packageAssignee: David Williams <david_williams>
Status: CLOSED WORKSFORME QA Contact:
Severity: normal    
Priority: P3 CC: aniefer, john.arthorne, mistria, mknauer, simon_kaegi, thomas
Version: unspecified   
Target Milestone: 1.1.0 RC1   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description David Williams CLA 2009-05-28 01:21:23 EDT
latest build had "old" platform splash screen, instead of new one: 

-showsplash
org.eclipse.epp.package.jee

Also, the config.ini file has "old" product and splash screen. 
Not sure if these _have_ to be changed ... or, if the eclipse.ini is supposed to override those?
Comment 1 David Williams CLA 2009-05-28 01:59:34 EDT
John, CCing you hoping for a quick answer on if config.ini should match eclipse.ini (that is, each used by different code, for different things) or is it just redundant information where one overrides the other? 
Comment 2 Markus Knauer CLA 2009-05-28 04:11:07 EDT
I think I found the reason... look in the p2.inf file of the package (see the package feature) and in the p2.inf file of the platform. I will try to modify this and will add a patch later today.

This affects nearly every package.
Comment 3 John Arthorne CLA 2009-05-28 09:26:59 EDT
Re: eclipse.ini vs. config.ini: they can both set system properties, but they are interpreted by different code at different parts of the startup sequence. eclipse.ini is processed by the native launcher, and config.ini is processed by the Equinox framework in Java code. Generally eclipse.ini is only used for information needed by the launcher (vm path and arguments, splash info, etc).
Comment 4 David Williams CLA 2009-05-28 09:36:59 EDT
(In reply to comment #2)

> ... and in the p2.inf file of the platform. ... 

Where is this p2.inf file? I don't see it in the org.eclipse.sdk plugin or feature I have checked out. 


Comment 5 Markus Knauer CLA 2009-05-28 12:02:13 EDT
(In reply to comment #4)
> (In reply to comment #2)
> 
> > ... and in the p2.inf file of the platform. ...
> 
> Where is this p2.inf file? I don't see it in the org.eclipse.sdk plugin or
> feature I have checked out.

I meant this here in the Eclipse project CVS:

:pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse
/org.eclipse.releng.eclipsebuilder/eclipse/buildConfigs/platform/p2.inf
Comment 6 Markus Knauer CLA 2009-05-28 12:37:21 EDT
Another question, maybe to John and Thomas? ;-)

It is still not working as expected but I have a theory....
Files can be found in the EPP CVS (...@dev.eclipse.org:/cvsroot/technology in  packaging/org.eclipse.epp/packages/org.eclipse.epp.package.jee.feature)

Problem: config.ini contains unwanted values, e.g. in the JEE package (e.g. build 20090528-0607 from http://www.eclipse.org/epp/download.php)

  eclipse.product=org.eclipse.platform.ide
  osgi.splashPath=platform\:/base/plugins/org.eclipse.platform

My solution: Add 'something' to the p2.inf file in the org.eclipse.epp.package.jee.feature

instructions.configure=\
  setProgramProperty(propName:osgi.splashPath, propValue:platform:/base/plugins/org.eclipse.epp.package.jee);\
  setProgramProperty(propName:eclipse.product,propValue:org.eclipse.epp.package.jee.product);\
  setProgramProperty(propName:eclipse.application,propValue:org.eclipse.ui.ide.workbench);
  
instructions.unconfigure=\
  setProgramProperty(propName:osgi.splashPath,propValue:);\
  setProgramProperty(propName:eclipse.product,propValue:);\
  setProgramProperty(propName:eclipse.application,propValue:);

When using the org.eclipse.equinox.p2.director in order to create a package from the repository, I got the following error messages:

> /opt/eclipse/64/eclipse.3.5RC2/eclipse -nosplash -consoleLog \                                                                                                 
> -application org.eclipse.equinox.p2.director \                                                                                                                               
> -m file:///home/data/httpd/download.eclipse.org/releases/staging/,file:///home/data/httpd/download.eclipse.org/eclipse/updates/3.5milestones/S-3.5RC2-200905221710/,file:///tmp/site.p2/ \                                                                                                                                                                  
> -a file:///home/data/httpd/download.eclipse.org/releases/staging/,file:///home/data/httpd/download.eclipse.org/eclipse/updates/3.5milestones/S-3.5RC2-200905221710/,file:///tmp/site.p2/ \                                                                                                                                                                  
> -installIU epp.package.jee \                                                                                                                                                 
> -destination /tmp/epp/eclipse \                                                                                                                                              
> -profile epp.package.jee \                                                                                                                                                   
> -flavor tooling \                                                                                                                                                            
> -profileProperties org.eclipse.update.install.features=true \                                                                                                                
> -bundlepool /tmp/epp/eclipse \                                                                                                                                               
> -p2.os linux -p2.ws gtk -p2.arch x86_64 \                                                                                                                                    
> -roaming -vmargs -Declipse.p2.mirrors=false -Declipse.p2.data.area=/tmp/epp/eclipse/p2                                                                                       

Installing epp.package.jee 1.2.0.20090528-1452.                                   
An error occurred while configuring the installed items                           
 session context was:(profile=epp.package.jee, phase=org.eclipse.equinox.internal.provisional.p2.engine.phases.Configure, operand=null --> [R]org.eclipse.epp.package.jee.feature.feature.group 1.2.0.20090528-1452, action=org.eclipse.equinox.internal.provisional.p2.engine.MissingAction).                                                                
 No action found for: setProgramProperty.                                                                                                                                      
Caused by: Application failed, log file location: /opt/eclipse/64/eclipse.3.5RC2/configuration/1243524175695.log                                                               
!SESSION 2009-05-28 17:22:55.429 -----------------------------------------------                                                                                               
eclipse.buildId=I20090522-1710                                                                                                                                                 
java.version=1.6.0_0                                                                                                                                                           
java.vendor=Sun Microsystems Inc.                                                                                                                                              
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_GB                                                                                                                  
Framework arguments:  -application org.eclipse.equinox.p2.director -m file:///home/data/httpd/download.eclipse.org/releases/staging/,file:///home/data/httpd/download.eclipse.org/eclipse/updates/3.5milestones/S-3.5RC2-200905221710/,file:///tmp/site.p2/ -a file:///home/data/httpd/download.eclipse.org/releases/staging/,file:///home/data/httpd/download.eclipse.org/eclipse/updates/3.5milestones/S-3.5RC2-200905221710/,file:///tmp/site.p2/ -installIU epp.package.jee -destination /tmp/epp/eclipse -profile epp.package.jee -flavor tooling -profileProperties org.eclipse.update.install.features=true -bundlepool /tmp/epp/eclipse -p2.os linux -p2.ws gtk -p2.arch x86_64 -roaming                            
Command-line arguments:  -os linux -ws gtk -arch x86_64 -consoleLog -application org.eclipse.equinox.p2.director -m file:///home/data/httpd/download.eclipse.org/releases/staging/,file:///home/data/httpd/download.eclipse.org/eclipse/updates/3.5milestones/S-3.5RC2-200905221710/,file:///tmp/site.p2/ -a file:///home/data/httpd/download.eclipse.org/releases/staging/,file:///home/data/httpd/download.eclipse.org/eclipse/updates/3.5milestones/S-3.5RC2-200905221710/,file:///tmp/site.p2/ -installIU epp.package.jee -destination /tmp/epp/eclipse -profile epp.package.jee -flavor tooling -profileProperties org.eclipse.update.install.features=true -bundlepool /tmp/epp/eclipse -p2.os linux -p2.ws gtk -p2.arch x86_64 -roaming                                                                                                                                                             

!ENTRY org.eclipse.equinox.p2.engine 4 4 2009-05-28 17:38:33.031
!MESSAGE An error occurred while configuring the installed items
!SUBENTRY 1 org.eclipse.equinox.p2.engine 4 0 2009-05-28 17:38:33.032
!MESSAGE session context was:(profile=epp.package.jee, phase=org.eclipse.equinox.internal.provisional.p2.engine.phases.Configure, operand=null --> [R]org.eclipse.epp.package.jee.feature.feature.group 1.2.0.20090528-1452, action=org.eclipse.equinox.internal.provisional.p2.engine.MissingAction).
!SUBENTRY 1 org.eclipse.equinox.p2.engine 4 0 2009-05-28 17:38:33.033
!MESSAGE No action found for: setProgramProperty.
!STACK 0
java.lang.IllegalArgumentException: No action found for: setProgramProperty.
        at org.eclipse.equinox.internal.provisional.p2.engine.MissingAction.execute(MissingAction.java:38)
        at org.eclipse.equinox.internal.provisional.p2.engine.Phase.mainPerform(Phase.java:129)
        at org.eclipse.equinox.internal.provisional.p2.engine.Phase.perform(Phase.java:72)
        at org.eclipse.equinox.internal.provisional.p2.engine.PhaseSet.perform(PhaseSet.java:44)
        at org.eclipse.equinox.internal.provisional.p2.engine.Engine.perform(Engine.java:54)
        at org.eclipse.equinox.internal.provisional.p2.director.PlanExecutionHelper.executePlan(PlanExecutionHelper.java:41)
        at org.eclipse.equinox.internal.provisional.p2.director.PlanExecutionHelper.executePlan(PlanExecutionHelper.java:23)
        at org.eclipse.equinox.internal.p2.director.app.DirectorApplication.planAndExecute(DirectorApplication.java:506)
        at org.eclipse.equinox.internal.p2.director.app.DirectorApplication.performProvisioningActions(DirectorApplication.java:492)
        at org.eclipse.equinox.internal.p2.director.app.DirectorApplication.run(DirectorApplication.java:707)
        at org.eclipse.equinox.internal.p2.director.app.DirectorApplication.start(DirectorApplication.java:807)
        at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:616)
        at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:559)
        at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
        at org.eclipse.equinox.launcher.Main.run(Main.java:1311)
        at org.eclipse.equinox.launcher.Main.main(Main.java:1287)



By looking into the content.jar I found the touchpoint instructions several times. I found it in the IU epp.package.jee (from the product - expected), in toolingepp.package.jee.ini... (?), and in the org.eclipse.epp.package.jee.feature.feature.group (from the feature - unexpected!).

I assume that

(1) this duplicated instructions are causing this error - could this be the reason for the failure above?
(2) the problem is caused by the way we are building the repository.

Background information:

'Our' features contain both, the feature definition *and* the epp.product file that is used to build everything with Buckminster.
What do we need to change? Or what *can* we change? Or are there other explanations for this error?
Comment 7 Markus Knauer CLA 2009-06-03 09:55:41 EDT
Maybe my written text was too long to be read by anybody, but the issue still remains the same... any ideas why it is not possible to control the content of the content.ini in this scenario?
Comment 8 John Arthorne CLA 2009-06-03 10:40:36 EDT
What is the touchpoint id for this installable unit? It would need to be "org.eclipse.equinox.p2.osgi" to be able to use the setProgramProperty action.
Comment 9 Markus Knauer CLA 2009-06-04 10:02:13 EDT
Thanks for updating the documentation on the wiki, especially 

  http://wiki.eclipse.org/Equinox/p2/Engine/Touchpoint_Instructions and
  http://wiki.eclipse.org/Equinox/p2/Customizing_Metadata
  
together with the last comment ;-) helped a lot. My status is now that I am able to modify things [setProgramProperty(propName:osgi.splashPath)] but I assume that my modifications are overwritten from another IU (e.g. toolingorg.eclipse.platform.ide.config...) afterwards and therefore not visible any more.

Is it possible to define an ordering? Maybe by defining some dependencies?
Comment 10 Simon Kaegi CLA 2009-06-04 11:33:17 EDT
(In reply to comment #9)
-snip-
>My status is now that I am
> able to modify things [setProgramProperty(propName:osgi.splashPath)] but I
> assume that my modifications are overwritten from another IU (e.g.
> toolingorg.eclipse.platform.ide.config...) afterwards and therefore not visible
> any more.
> Is it possible to define an ordering? Maybe by defining some dependencies?

I'd avoid clever ordering as an approach for sorting this out as when setting properties it's last writer winds so you can get in a real mess based on the order things get installed, uninstalled, and updated. You're better to only 
have one IU setting this property.

I think the real issue is that you're try to re-use an existing product (org.eclipse.sdk.ide) and then also define another product in an incompatible way. Re-using another product is really tricky to do on a good day. If you want to "override" any settings of the product (instead of just adding to it) you're in a situation where you have to stop consuming the existing product (e.g. org.eclipse.sdk.ide) and instead create your own stand-alone product.

Comment 11 Andrew Niefer CLA 2009-06-04 12:15:22 EDT
The original suggestion of EPP reusing the platform products was made with the understanding that you would not want to change any of the product branding (which includes splash screen and launchers).

Also, RE comment #6, you are going to have this same problem for setting the program property "eclipse.product".  For that you will need to set program arguments "-product" which shows up in the eclipse.ini and override the "eclipse.product" value in the config.ini.

You will not be able to override the splash screen in the same way because the platform already specifies a -showsplash in the eclipse.ini
Comment 12 Markus Knauer CLA 2009-06-04 13:59:56 EDT
Yepp, I can understand what you mentioned in comments #10 and #11.

To me there are two questions:

(1) to the package maintainer(s): I hope it is acceptable that the splash screen cannot be changed in the EPP packages. I think it is acceptable because it is not a regression compared to what we did in Ganymede. Then: Please close the bug.

(2) to Andrew and Simon: This is more a p2 related question, but the case "IU_2 overrides IU_1" is a *should_not_happen* case, that's fore sure, but it *can* happen and there seems to be no protection against it. But this is probably a topic of another discussion.
Comment 13 David Williams CLA 2009-06-04 14:34:12 EDT
(In reply to comment #12)

> 
> (1) to the package maintainer(s): I hope it is acceptable that the splash
> screen cannot be changed in the EPP packages. I think it is acceptable because
> it is not a regression compared to what we did in Ganymede. Then: Please close
> the bug.
> 

Well .. I'm not ready to give up yet! 

Why do we have to "reuse" the "platform product"? What do we get from it? 
Is the alternative to copy/paste some stuff into our jee product? 
I think we are going to have to do that anyway, for "capabilities" so I'm wondering what the general recommendation is or why this would be so hard to do? 



Comment 14 Andrew Niefer CLA 2009-06-04 15:13:20 EDT
(In reply to comment #13)
> Why do we have to "reuse" the "platform product"? What do we get from it? 
> Is the alternative to copy/paste some stuff into our jee product? 
> I think we are going to have to do that anyway, for "capabilities" so I'm
> wondering what the general recommendation is or why this would be so hard to
> do? 
> 

You don't need to reuse the whole platform product.  You will want to reuse the org.eclipse.rcp.configuration feature group that brings in the launchers.  You will need to define all the other configuration (startlevels, etc.) yourselves. 

You can look at the sdk.product (and its p2.inf)
/cvsroot/eclipse/org.eclipse.releng.eclipsebuilder\eclipse\buildConfigs\sdk\builder\sdk.product
and copy a lot of what you see there.

Note that this .product file is published directly and not put through a product build, if you are publishing via product build, the inclusion of org.eclipse.rcp.configuration.feature.group will need to be done via p2.inf instead of directly listing it in the .product file.

This is a not-insignificant change, and this late in the game I'm not sure a splash screen is worth it.
Comment 15 David Williams CLA 2009-06-04 15:32:40 EDT
(In reply to comment #14)
> (In reply to comment #13)

I think it'd be worth it, if Markus is willing to try. 

It is not literally just the splash screen, but seems to me part of the purpose is to "set an example" of how to do things. I'm assuming what Andrew suggests is indeed the recommended way to 'make a product"? Or, is it a work around for what would be considered a Platform bug? 

Comment 16 Andrew Niefer CLA 2009-06-04 15:49:16 EDT
I general we would not recommend reusing the platform products for the same branding reasons we've hit here.  There is bug 276125 where we are trying to restructure the platform's metadata to make it easier to reuse parts of the configuration, but we ran out of time in 3.5.


So yes, in general right now products should define their configuration themselves.
Comment 17 Markus Knauer CLA 2009-06-04 15:54:23 EDT
Yepp, I am willing to try it out... but I would suggest that we leave it as it is in *RC3* and try to get it into *RC4* next week if we can make sure that everything works. If we can get it running until, let's say Tuesday, we put it into next weeks build, otherwise we can discuss if we roll back the changes.
Comment 18 David Williams CLA 2009-06-04 16:04:56 EDT
(In reply to comment #17)

Agreed, RC4 is fine. 
 

Comment 19 Mickael Istria CLA 2017-10-22 11:21:44 EDT
8 years without comment, and everything seems good now. Closing.