Page 1 of 1

Invoking by double-click on .rdb file

Posted: Thu Dec 15, 2016 3:35 pm
by HughDarwen
(Shouldn't this section be renamed now that Dbrowser doesn't exist under that name?)

So I eventually managed to get double-click on .rdb to work in V3.2 on Windows 10. I ran into a couple of minor problems to begin with. Both have gone away now so I don't need any fixes for them, but I thought I should report them anyway.

1. The very first attempt to double-click on ClickToOpen.rdb actually failed. See the log file copied below.

2. The second attempt worked but my preferences previously set for the same database had reverted to the defaults.

Hugh

Log for point 1:

!SESSION 2016-12-15 14:33:34.996 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.8.0_101
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_GB
Framework arguments: -clearPersistedState Rel D:\AllDocs\AllRelDatabases\DDMP\ClickToOpen.rdb
Command-line arguments: -os win32 -ws win32 -arch x86_64 -clearPersistedState Rel D:\AllDocs\AllRelDatabases\DDMP\ClickToOpen.rdb

!ENTRY org.eclipse.osgi 4 0 2016-12-15 14:33:36.496
!MESSAGE An error occurred while automatically activating bundle org.eclipse.core.resources (32).
!STACK 0
org.osgi.framework.BundleException: Exception in org.eclipse.core.resources.ResourcesPlugin.start() of bundle org.eclipse.core.resources.
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:795)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:724)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:932)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:309)
at org.eclipse.osgi.container.Module.doStart(Module.java:581)
at org.eclipse.osgi.container.Module.start(Module.java:449)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:470)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:529)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:325)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:345)
at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:36)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:419)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:372)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:364)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:161)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at org.eclipse.emf.ecore.plugin.EcorePlugin.getWorkspaceRoot(EcorePlugin.java:1131)
at org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl.<clinit>(ExtensibleURIConverterImpl.java:393)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getURIConverter(ResourceSetImpl.java:499)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:369)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.getResource(ResourceHandler.java:289)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.loadResource(ResourceHandler.java:265)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.loadMostRecentModel(ResourceHandler.java:181)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.loadApplicationModel(E4Application.java:377)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.createE4Workbench(E4Application.java:252)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.start(E4Application.java:148)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)
at org.eclipse.equinox.launcher.Main.run(Main.java:1519)
Caused by: java.lang.IllegalStateException: The platform metadata area could not be written: C:\Windows\System32\workspace\.metadata. By default the platform writes its content
under the current working directory when the platform is launched. Use the -data parameter to
specify a different content area for the platform.
at org.eclipse.core.internal.runtime.DataArea.assertLocationInitialized(DataArea.java:61)
at org.eclipse.core.internal.runtime.DataArea.getStateLocation(DataArea.java:124)
at org.eclipse.core.internal.runtime.InternalPlatform.getStateLocation(InternalPlatform.java:539)
at org.eclipse.core.runtime.Plugin.getStateLocation(Plugin.java:289)
at org.eclipse.core.internal.resources.LocalMetaArea.<init>(LocalMetaArea.java:59)
at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:456)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:774)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:767)
... 38 more
Root exception:
java.lang.IllegalStateException: The platform metadata area could not be written: C:\Windows\System32\workspace\.metadata. By default the platform writes its content
under the current working directory when the platform is launched. Use the -data parameter to
specify a different content area for the platform.
at org.eclipse.core.internal.runtime.DataArea.assertLocationInitialized(DataArea.java:61)
at org.eclipse.core.internal.runtime.DataArea.getStateLocation(DataArea.java:124)
at org.eclipse.core.internal.runtime.InternalPlatform.getStateLocation(InternalPlatform.java:539)
at org.eclipse.core.runtime.Plugin.getStateLocation(Plugin.java:289)
at org.eclipse.core.internal.resources.LocalMetaArea.<init>(LocalMetaArea.java:59)
at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:456)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:774)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:767)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:724)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:932)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:309)
at org.eclipse.osgi.container.Module.doStart(Module.java:581)
at org.eclipse.osgi.container.Module.start(Module.java:449)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:470)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:529)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:325)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:345)
at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:36)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:419)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:372)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:364)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:161)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at org.eclipse.emf.ecore.plugin.EcorePlugin.getWorkspaceRoot(EcorePlugin.java:1131)
at org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl.<clinit>(ExtensibleURIConverterImpl.java:393)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getURIConverter(ResourceSetImpl.java:499)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:369)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.getResource(ResourceHandler.java:289)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.loadResource(ResourceHandler.java:265)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.loadMostRecentModel(ResourceHandler.java:181)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.loadApplicationModel(E4Application.java:377)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.createE4Workbench(E4Application.java:252)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.start(E4Application.java:148)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)
at org.eclipse.equinox.launcher.Main.run(Main.java:1519)

!ENTRY org.eclipse.osgi 4 0 2016-12-15 14:33:36.528
!MESSAGE Application error
!STACK 1
java.lang.NoClassDefFoundError: org/eclipse/core/resources/ResourcesPlugin
at org.eclipse.emf.ecore.plugin.EcorePlugin.getWorkspaceRoot(EcorePlugin.java:1131)
at org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl.<clinit>(ExtensibleURIConverterImpl.java:393)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getURIConverter(ResourceSetImpl.java:499)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:369)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.getResource(ResourceHandler.java:289)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.loadResource(ResourceHandler.java:265)
at org.eclipse.e4.ui.internal.workbench.ResourceHandler.loadMostRecentModel(ResourceHandler.java:181)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.loadApplicationModel(E4Application.java:377)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.createE4Workbench(E4Application.java:252)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application.start(E4Application.java:148)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)
at org.eclipse.equinox.launcher.Main.run(Main.java:1519)
Caused by: java.lang.ClassNotFoundException: An error occurred while automatically activating bundle org.eclipse.core.resources (32).
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:116)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:529)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:325)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:345)
at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:36)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:419)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:372)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:364)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:161)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 22 more
Caused by: org.osgi.framework.BundleException: Exception in org.eclipse.core.resources.ResourcesPlugin.start() of bundle org.eclipse.core.resources.
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:795)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:724)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:932)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:309)
at org.eclipse.osgi.container.Module.doStart(Module.java:581)
at org.eclipse.osgi.container.Module.start(Module.java:449)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:470)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
... 31 more
Caused by: java.lang.IllegalStateException: The platform metadata area could not be written: C:\Windows\System32\workspace\.metadata. By default the platform writes its content
under the current working directory when the platform is launched. Use the -data parameter to
specify a different content area for the platform.
at org.eclipse.core.internal.runtime.DataArea.assertLocationInitialized(DataArea.java:61)
at org.eclipse.core.internal.runtime.DataArea.getStateLocation(DataArea.java:124)
at org.eclipse.core.internal.runtime.InternalPlatform.getStateLocation(InternalPlatform.java:539)
at org.eclipse.core.runtime.Plugin.getStateLocation(Plugin.java:289)
at org.eclipse.core.internal.resources.LocalMetaArea.<init>(LocalMetaArea.java:59)
at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:456)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:774)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:767)
... 38 more

Re: Invoking by double-click on .rdb file

Posted: Thu Dec 15, 2016 9:12 pm
by Dave
HughDarwen wrote:(Shouldn't this section be renamed now that Dbrowser doesn't exist under that name?)
Good point. I've renamed it.
HughDarwen wrote: So I eventually managed to get double-click on .rdb to work in V3.2 on Windows 10. I ran into a couple of minor problems to begin with. Both have gone away now so I don't need any fixes for them, but I thought I should report them anyway.

1. The very first attempt to double-click on ClickToOpen.rdb actually failed. See the log file copied below.
Strange. The error log suggests that it tried to save the preferences to a file in C:\Windows\System32, which is not allowed. That can occur if the current directory was C:\Windows\System32 when Rel.exe was launched, which normally shouldn't happen. When this happened, how was Rel.exe launched? Was it by clicking on the Rel.exe file or something else?
HughDarwen wrote: 2. The second attempt worked but my preferences previously set for the same database had reverted to the defaults.
Under Windows, it will normally store the preferences in the directory where Rel.exe is launched from, rather than the directory where Rel.exe is stored.

Re: Invoking by double-click on .rdb file

Posted: Thu Dec 15, 2016 9:28 pm
by Dave
Dave wrote:
HughDarwen wrote: So I eventually managed to get double-click on .rdb to work in V3.2 on Windows 10. I ran into a couple of minor problems to begin with. Both have gone away now so I don't need any fixes for them, but I thought I should report them anyway.

1. The very first attempt to double-click on ClickToOpen.rdb actually failed. See the log file copied below.
Strange. The error log suggests that it tried to save the preferences to a file in C:\Windows\System32, which is not allowed. That can occur if the current directory was C:\Windows\System32 when Rel.exe was launched, which normally shouldn't happen. When this happened, how was Rel.exe launched? Was it by clicking on the Rel.exe file or something else?
I managed to replicate this by experimenting with the Windows file associations, which if done properly (?) results in Windows attempting to launch Rel.exe with the current directory set to C:\Windows\System32 rather than the directory containing Rel.exe

I'd argue that this is a Windows bug (I don't know if Microsoft would agree, though...) because there's no reason for anything to use C:\Windows\System32 as the current directory except for (maybe) running the utilities in C:\Windows\System32.

I'll see what I can do to make Rel avoid trying to store preferences in C:\Windows\System32.

Re: Invoking by double-click on .rdb file

Posted: Fri Dec 16, 2016 4:55 pm
by HughDarwen
Okay, I now see that preferences are stored in rel.reldb.org. I was being inconsistent in directories I was starting Rel.exe in. Now I'm trying to make sure I always start in the directory containing the database I'm starting with, defaulting to the Rel-provided default one.

I can't think of a way in which I might have started in c:\windows\system32 but I have had no repetition of that first-time failure. I'm certainly not waiting on that fix you say you'll attempt, so please don't bust a gut on it.

Hugh