Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Oomph » Validate Java runtime and product version on bootstrap and start(The java runtime and product version selected should be validatable by an installation setup during bootstrap)
Validate Java runtime and product version on bootstrap and start [message #1854949] Tue, 20 September 2022 08:39 Go to next message
Markus Hoffrogge is currently offline Markus HoffroggeFriend
Messages: 7
Registered: March 2020
Junior Member
We are using Oomph installer / setup for wide range of customer projects to ensure consistent environments for our team members.

Is there a possibility to validate the Java runtime and the product version - and ideally also the product variant the user did select on the first installer dialog?

This check shall be configurable as a setup task at least for the bootstrap as well as for the start trigger phase.

If there is no possibility yet, could you give some hints how a new task implementation would have to get this information and check this?

Kind regards
Markus
Re: Validate Java runtime and product version on bootstrap and start [message #1854961 is a reply to message #1854949] Tue, 20 September 2022 14:44 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33251
Registered: July 2009
Senior Member
I don't really understand the "task". I.e., what exactly is being validated? The only information directly available to a task is what's in the org.eclipse.oomph.setup.SetupTaskContext so I don't think the kind of things you'd want to validate would be available via that mechanism such that you could implement it a bootstrap time. In the running IDE you can inspect/validate anything that is installed and anything in the workspace.

Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Validate Java runtime and product version on bootstrap and start [message #1854991 is a reply to message #1854961] Thu, 22 September 2022 12:53 Go to previous messageGo to next message
Markus Hoffrogge is currently offline Markus HoffroggeFriend
Messages: 7
Registered: March 2020
Junior Member
We would like to define an oomph setupTask within our project setup definitions which allows to define an expected Eclipse product version/variant as well as the expected Java runtime version for the target Eclipse installation.

This oomph setup task should verify, that the Eclipse product version and the Java runtime version that has been selected by the user meets the expected values configured within the project setup.

Since the Oomph installer is creating the eclipse.ini file with the target Eclipse version launcher .jar configured as well as an entry for the -vm option for the targets Java runtime, this information should also be available for a setupTask during bootstrap - correct?

Then we would like to come up with an error message from this verifying setupTask and abort the further installation.

If this is too complicated to do it during the bootstrap phase, then we would like to do it on the first targets start phase.

So our question is how can we get that information of the target Eclipse product version and variant as well as the Java runtime selected on the first setup dialog.
Re: Validate Java runtime and product version on bootstrap and start [message #1854994 is a reply to message #1854991] Thu, 22 September 2022 14:17 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33251
Registered: July 2009
Senior Member
The information at bootstrap time is not (currently) available to any specific task via the SetupTaskContext. E.g., something like the eclipse.ini's -vm option might well depend on what some EclipseIni task does when it's performed.

I'm not sure if you are aware of Configuration. These are useful for installing a specific combination of product version and project streams:

https://wiki.eclipse.org/Eclipse_Oomph_Authoring#Automation_and_Specialization_with_Configurations

The Java runtime of a running IDE you can of course query directly via the system properties. The product version is referenced from the Installation in the resource loaded from this URI .eclipse.oomph.setup.internal.core.SetupContext.INSTALLATION_SETUP_URI.


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:Conditional setup task for empty workspaces
Next Topic:Exception when trying to run the installer or setup tasks
Goto Forum:
  


Current Time: Mon Nov 04 15:44:35 GMT 2024

Powered by FUDForum. Page generated in 0.03239 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top