[
https://issues.jboss.org/browse/JBIDE-19697?page=com.atlassian.jira.plugi...
]
Snjezana Peco commented on JBIDE-19697:
---------------------------------------
The following is the code
(
https://github.com/jbosstools/jbosstools-base/blob/jbosstools-4.3.0.Alpha...):
{code}
...
private static final String LOCATIONS_FILE_NAME =
"runtime_locations.properties"; //$NON-NLS-1$
private static final String LOCATIONS_FILE = "../../../../studio/" +
LOCATIONS_FILE_NAME; //$NON-NLS-1$
private static final String LOCATIONS_FILE_CONFIGURATION = "../../studio/" +
LOCATIONS_FILE_NAME; //$NON-NLS-1$
...
private static File findRuntimeFile() {
try {
String pluginLocation =
FileLocator.resolve(RuntimeUIActivator.getDefault().getBundle().getEntry("/")).getPath();
//$NON-NLS-1$
File serversFile = new File(pluginLocation, LOCATIONS_FILE);
if (!serversFile.isFile()) {
String configuration = getConfiguration();
serversFile = new File(configuration, LOCATIONS_FILE_CONFIGURATION).getCanonicalFile();
} else {
serversFile = serversFile.getCanonicalFile();
}
if (!serversFile.isFile()) {
serversFile = new File(pluginLocation,LOCATIONS_FILE_NAME);
}
if (serversFile.isFile()) {
return serversFile;
}
} catch(IOException ioe) {
RuntimeUIActivator.pluginLog().logError(ioe);
}
return null;
}
{code}
I suppose you have
pluginLocation=/Users/rasp/jbossqa/JBDS/9.0.0/Eclipse-runtime-test.app/Contents/Eclipse/plugins/org.jboss.tools.runtime.ui_<VERSION>
configuration=/Users/rasp/jbossqa/JBDS/9.0.0/Eclipse-runtime-test.app/Eclipse-runtime-test.app/Contents/Eclipse/
org.jboss.tools.runtime.ui.prefs mysteriously appears in Eclipse dir
during JBDS BYOE installation
--------------------------------------------------------------------------------------------------
Key: JBIDE-19697
URL:
https://issues.jboss.org/browse/JBIDE-19697
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: runtime-detection
Affects Versions: 4.3.0.Alpha2
Reporter: Martin Malina
Assignee: Snjezana Peco
When I install JBDs 9.0.0.Alpha2 B24 BYOE into new Eclipse Mars M6 and new workspace,
during the installation, suddenly the runtime detection config appears inside my Eclipse
isntall dir:
{code}
$ find Eclipse-runtime-test.app/ -name 'org.jboss.tools.runtime.*.prefs'
Eclipse-runtime-test.app//Contents/Eclipse/configuration/.settings/org.jboss.tools.runtime.ui.prefs
{code}
This is inside the file:
{code}
$ find Eclipse-runtime-test.app/ -name 'org.jboss.tools.runtime.*.prefs'|xargs
cat
eclipse.preferences.version=1
runtimePaths=<?xml version\="1.0" encoding\="UTF-8"
standalone\="no"?>\n<runtimePaths version\="2">\n
<runtimePath path\="/Users/rasp/jbossqa/runtimes/jboss-eap-6.3.0"
scanOnEveryStartup\="false" timestamp\="-1">\n
<serverDefinitions>\n <serverDefinition description\=""
enabled\="true"
location\="/Users/rasp/jbossqa/runtimes/jboss-eap-6.3.0" name\="JBoss EAP
6.3" type\="EAP" version\="6.3">\n <included/>\n
</serverDefinition>\n </serverDefinitions>\n
</runtimePath>\n</runtimePaths>\n
{code}
It contains /Users/rasp/jbossqa/runtimes/jboss-eap-6.3.0 which I use regularly when
testing server tooling. But how did this happen?
I looked for the pref file before I started BYOE installation. Then a bit later, a few
minutes into the installation, I checked again and the file is there now.
Can somebody explain what's going on?
Note: This happened to me yesterday and it surprised me, but I wasn't sure if it
wasn't my mistake somehow. But Max preferred I try again, so I did. And it is
happening again now.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)