Local Root or Folder Search Path for JVM

The public knowledge pool and discussion forum of the OWS community. Do not post confidential information here!
cshooshan
Posts: 3
Joined: 24 Jun 2020, 16:11

Local Root or Folder Search Path for JVM

Post by cshooshan »

Good day!

I really love OpenWebStart.

I have OpenWebStart and my JVM both installed to the root of a flash drive in \OpenWebStart and \JDK64 respectively.

I would love it if OpenWebStart could autodetect the JVM on the flash drive so that I could run javaws without first pointing to \JDK64 using itw-settings each time I use the flash drive in a new computer.

Maybe there is a way to install the full JDK inside the OpenWebStart folder?

Thanks,
Charlie

Janak Mulani
Posts: 726
Joined: 24 Mar 2020, 13:37

Re: Local Root or Folder Search Path for JVM

Post by Janak Mulani »

Hello Charlie,

Thanks for using OWS.

You can configure JVM Manager by using the tool itw-settings and then choosing JVM Manager.

This post https://board.karakun.com/viewtopic.php?f=21&t=61, though not a direct answer to your question, describes the folder in which OWS JVM Manager looks for local JVMs when you select "Find Local". You can even add the JVM of your choice by choosing "Add Local". Once you have installed a JVM and subsequently would like to keep it upto date then you can choose Settings.. and specify update strategies and the server from which to download newer versions of JVMs. The updated JVMs are installed in User Home\.cache\icedtea-web\jvm-cache directory

You can customize the location of JVM Cache dir by specifying the property ows.jvm.manager.cache.dir in the deployment.properties file found in User Home\.config\icedtea-web directory. For instance

Code: Select all

ows.jvm.manager.cache.dir=c\:/temp/JVMCache

cshooshan
Posts: 3
Joined: 24 Jun 2020, 16:11

Re: Local Root or Folder Search Path for JVM

Post by cshooshan »

Your answer is very helpful!

I am hoping to have something like a local copy of deployment.properties would be available on the flash drive and could be consulted without having to rely on a file in the Home folder.

My idea is that if javaws finds a copy "near" the install directory of deployment.properties, it would use that one and not the one in the Home directory.

My goal is for the install on the flash drive to be machine independent.

This would also require that relative folder locations be permitted in the property (since the drive letter could change machine-to-machine).

When there were JVM that could execute JNLP files, I would put a .bat or .exec file in the root of the flash drive that would append PATH and ENV before running my IDE.

Thanks,
Charlie

Stephan Classen
Posts: 232
Joined: 27 Mar 2020, 09:55

Re: Local Root or Folder Search Path for JVM

Post by Stephan Classen »

Unfortunately neither ITW nor OWS have any functionality for detecting configs relative to the installation folder.
There is however the option to specify the location of the config and the cache folder using environment variables.

XDG_CACHE_HOME
XDG_CONFIG_HOME

So it should be possible to write a batch script which composes two path relative to the script.
Then sets the above environment variables to the computed path.
And finally launch OpenWebStart.

cshooshan
Posts: 3
Joined: 24 Jun 2020, 16:11

Re: Local Root or Folder Search Path for JVM

Post by cshooshan »

That will work! I will try it.

Thanks for everything,
Charlie

Stephan Classen
Posts: 232
Joined: 27 Mar 2020, 09:55

Re: Local Root or Folder Search Path for JVM

Post by Stephan Classen »

Great to hear.
It would be appreciated if you could post your batch script once you have it running.
This would help others with a similar setup.

Post Reply