Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » Run As > Eclipse Application hangs(Run Eclipse Application gets root exception Attempted to beginRule: R/, does not match outer scope rule)
Run As > Eclipse Application hangs [message #1843595] Tue, 10 August 2021 10:22 Go to next message
Steve Vestal is currently offline Steve VestalFriend
Messages: 37
Registered: March 2013
Member
I am developing plugins using RCP 2020-06. Starting yesterday, attempting to run a child eclipse application started hanging. After several minutes, it times out.

This started occuring after pulling some work done by a coworker, who is not having this problem. Minor changes were made by myself to other projects. If I close the project whose changes were pulled, then Run As Eclipse Application will succeed.

As an experiment, I tried removing the old runtime-EclipseApplication folder. The launch attempt fails before creating a new one.

Below is the log. What should I try to fix this?

!ENTRY org.eclipse.osgi 4 0 2021-08-09 19:39:24.608
!MESSAGE An error occurred while automatically activating bundle org.eclipse.core.resources (107).
!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:864)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:792)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1015)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:365)
at org.eclipse.osgi.container.Module.doStart(Module.java:605)
at org.eclipse.osgi.container.Module.start(Module.java:468)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:493)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:117)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:571)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:346)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:398)
at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:41)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:473)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:171)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:499)
at org.eclipse.emf.ecore.plugin.EcorePlugin.getWorkspaceRoot(EcorePlugin.java:1149)
at org.eclipse.emf.ecore.resource.impl.PlatformResourceURIHandlerImpl.getWorkspaceRoot(PlatformResourceURIHandlerImpl.java:488)
at org.eclipse.emf.ecore.resource.impl.PlatformResourceURIHandlerImpl.<clinit>(PlatformResourceURIHandlerImpl.java:456)
at org.eclipse.emf.ecore.resource.URIHandler.<clinit>(URIHandler.java:51)
at org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl.<init>(ExtensibleURIConverterImpl.java:138)
at org.eclipse.emf.ecore.resource.URIConverter.<clinit>(URIConverter.java:739)
at org.eclipse.emf.ecore.plugin.URIMappingRegistryReader.readElement(URIMappingRegistryReader.java:72)
at org.eclipse.emf.ecore.plugin.RegistryReader.internalReadElement(RegistryReader.java:130)
at org.eclipse.emf.ecore.plugin.RegistryReader.access$0(RegistryReader.java:128)
at org.eclipse.emf.ecore.plugin.RegistryReader$1.registryChanged(RegistryReader.java:110)
at org.eclipse.core.internal.registry.ExtensionRegistry$1.run(ExtensionRegistry.java:941)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
at org.eclipse.core.internal.registry.ExtensionRegistry.processChangeEvent(ExtensionRegistry.java:938)
at org.eclipse.core.runtime.spi.RegistryStrategy.processChangeEvent(RegistryStrategy.java:264)
at org.eclipse.core.internal.registry.osgi.ExtensionEventDispatcherJob.run(ExtensionEventDispatcherJob.java:56)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
Caused by: java.lang.IllegalArgumentException: Attempted to beginRule: R/, does not match outer scope rule: org.eclipse.core.internal.registry.osgi.ExtensionEventDispatcherJob$1@48ec182f
at org.eclipse.core.runtime.Assert.isLegal(Assert.java:66)
at org.eclipse.core.internal.jobs.ThreadJob.illegalPush(ThreadJob.java:137)
at org.eclipse.core.internal.jobs.ThreadJob.push(ThreadJob.java:392)
at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88)
at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:298)
at org.eclipse.core.internal.resources.WorkManager.startup(WorkManager.java:318)
at org.eclipse.core.internal.resources.Workspace.startup(Workspace.java:2435)
at org.eclipse.core.internal.resources.Workspace.open(Workspace.java:2210)
at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:489)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:843)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:835)
... 30 more
Root exception:
java.lang.IllegalArgumentException: Attempted to beginRule: R/, does not match outer scope rule: org.eclipse.core.internal.registry.osgi.ExtensionEventDispatcherJob$1@48ec182f
at org.eclipse.core.runtime.Assert.isLegal(Assert.java:66)
at org.eclipse.core.internal.jobs.ThreadJob.illegalPush(ThreadJob.java:137)
at org.eclipse.core.internal.jobs.ThreadJob.push(ThreadJob.java:392)
at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88)
at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:298)
at org.eclipse.core.internal.resources.WorkManager.startup(WorkManager.java:318)
at org.eclipse.core.internal.resources.Workspace.startup(Workspace.java:2435)
at org.eclipse.core.internal.resources.Workspace.open(Workspace.java:2210)
at org.eclipse.core.resources.ResourcesPlugin.start(ResourcesPlugin.java:489)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:843)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:835)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:792)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1015)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:365)
at org.eclipse.osgi.container.Module.doStart(Module.java:605)
at org.eclipse.osgi.container.Module.start(Module.java:468)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:493)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:117)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:571)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:346)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:398)
at org.eclipse.osgi.internal.loader.sources.SingleSourcePackage.loadClass(SingleSourcePackage.java:41)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:473)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:171)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:499)
at org.eclipse.emf.ecore.plugin.EcorePlugin.getWorkspaceRoot(EcorePlugin.java:1149)
at org.eclipse.emf.ecore.resource.impl.PlatformResourceURIHandlerImpl.getWorkspaceRoot(PlatformResourceURIHandlerImpl.java:488)
at org.eclipse.emf.ecore.resource.impl.PlatformResourceURIHandlerImpl.<clinit>(PlatformResourceURIHandlerImpl.java:456)
at org.eclipse.emf.ecore.resource.URIHandler.<clinit>(URIHandler.java:51)
at org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl.<init>(ExtensibleURIConverterImpl.java:138)
at org.eclipse.emf.ecore.resource.URIConverter.<clinit>(URIConverter.java:739)
at org.eclipse.emf.ecore.plugin.URIMappingRegistryReader.readElement(URIMappingRegistryReader.java:72)
at org.eclipse.emf.ecore.plugin.RegistryReader.internalReadElement(RegistryReader.java:130)
at org.eclipse.emf.ecore.plugin.RegistryReader.access$0(RegistryReader.java:128)
at org.eclipse.emf.ecore.plugin.RegistryReader$1.registryChanged(RegistryReader.java:110)
at org.eclipse.core.internal.registry.ExtensionRegistry$1.run(ExtensionRegistry.java:941)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
at org.eclipse.core.internal.registry.ExtensionRegistry.processChangeEvent(ExtensionRegistry.java:938)
at org.eclipse.core.runtime.spi.RegistryStrategy.processChangeEvent(RegistryStrategy.java:264)
at org.eclipse.core.internal.registry.osgi.ExtensionEventDispatcherJob.run(ExtensionEventDispatcherJob.java:56)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
Re: Run As > Eclipse Application hangs [message #1843647 is a reply to message #1843595] Thu, 12 August 2021 04:39 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33142
Registered: July 2009
Senior Member
It looks like something is dynamically changing the available bundle very early during startup. I would set a breakpoint in the constructor of ExtensionEventDispatcherJob. When I launch a runtime instance, this job is not created.

Also, in PlatformResourceURIHandlerImpl.getWorkspaceRoot, the code is like this:
  protected static IWorkspaceRoot getWorkspaceRoot()
  {
    if (!cachedWorkspaceRootInitialized)
    {
      try
      {
        // If the resource bundle isn't available, we will always return null for this method.
        if (EMFPlugin.IS_RESOURCES_BUNDLE_AVAILABLE)
        {
          // This will throw an exception if the instance location is not yet initialized,
          // i.e., when EMF is used by some component before the the user chooses the workspace location.
          // In this case we will return null and try again later to initialize the cached workspace root instance.
          EcorePlugin.getPlugin().getStateLocation();
          cachedWorkspaceRoot = workspaceRoot = EcorePlugin.getWorkspaceRoot();
        }
        cachedWorkspaceRootInitialized = true;
      }
      catch (Exception exception)
      {
        // Ignore.
      }
    }
    return cachedWorkspaceRoot;
  }
So this does not log an exception and should not cause a "hang".

This sounds a bit like the description in this Bugzilla:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=574728

But that user never responded to any questions and did not help to provide a way to reproduce the problem...



Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:What is option -bootclasspath in java eclipse?
Next Topic:Can't find library-file in eclipse-test-framework-4.8
Goto Forum:
  


Current Time: Sat Apr 27 15:22:43 GMT 2024

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

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

Back to the top