You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Stefan Seifert (Jira)" <ji...@apache.org> on 2021/04/29 16:24:00 UTC

[jira] [Created] (SLING-10346) ResourceResolver: MapEntires.dispose throws NPE when vanity path is disabled

Stefan Seifert created SLING-10346:
--------------------------------------

             Summary: ResourceResolver: MapEntires.dispose throws NPE when vanity path is disabled
                 Key: SLING-10346
                 URL: https://issues.apache.org/jira/browse/SLING-10346
             Project: Sling
          Issue Type: Bug
          Components: ResourceResolver
    Affects Versions: Resource Resolver 1.7.4
            Reporter: Stefan Seifert
            Assignee: Stefan Seifert
             Fix For: Resource Resolver 1.7.6


example:
{noformat}
java.lang.AssertionError: For value JCR_MOCK (teardown): Unable to invoke method 'deactivate' for class org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator
	at io.wcm.testing.junit.rules.parameterized.RepeatedStatement.evaluate(RepeatedStatement.java:69)
	at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
	at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
	at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
	at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
	at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:542)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:770)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:464)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:210)
Caused by: java.lang.RuntimeException: Unable to invoke method 'deactivate' for class org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator
	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeMethod(OsgiServiceUtil.java:347)
	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeLifecycleMethod(OsgiServiceUtil.java:234)
	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.activateDeactivate(OsgiServiceUtil.java:98)
	at org.apache.sling.testing.mock.osgi.MockOsgi.deactivate(MockOsgi.java:272)
	at org.apache.sling.testing.mock.osgi.MockBundleContext.shutdown(MockBundleContext.java:448)
	at org.apache.sling.testing.mock.osgi.MockOsgi.shutdown(MockOsgi.java:371)
	at org.apache.sling.testing.mock.osgi.context.OsgiContextImpl.tearDown(OsgiContextImpl.java:58)
	at org.apache.sling.testing.mock.sling.context.SlingContextImpl.tearDown(SlingContextImpl.java:256)
	at io.wcm.testing.mock.aem.context.AemContextImpl.tearDown(AemContextImpl.java:105)
	at io.wcm.testing.mock.aem.junit.AemContext.access$2(AemContext.java:1)
	at io.wcm.testing.mock.aem.junit.AemContext$3.execute(AemContext.java:216)
	at io.wcm.testing.mock.aem.junit.AemContext$3.execute(AemContext.java:1)
	at io.wcm.testing.junit.rules.parameterized.RepeatedStatement.evaluate(RepeatedStatement.java:65)
	... 18 more
Caused by: java.lang.NullPointerException
	at org.apache.sling.resourceresolver.impl.mapping.MapEntries.dispose(MapEntries.java:530)
	at org.apache.sling.resourceresolver.impl.CommonResourceResolverFactoryImpl.deactivate(CommonResourceResolverFactoryImpl.java:339)
	at org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator.unregisterFactory(ResourceResolverFactoryActivator.java:500)
	at org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator.unregisterFactory(ResourceResolverFactoryActivator.java:485)
	at org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator.deactivate(ResourceResolverFactoryActivator.java:454)
	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.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeMethod(OsgiServiceUtil.java:338)
	... 30 more

java.lang.AssertionError: For value JCR_OAK (teardown): Unable to invoke method 'deactivate' for class org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator
	at io.wcm.testing.junit.rules.parameterized.RepeatedStatement.evaluate(RepeatedStatement.java:69)
	at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
	at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
	at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
	at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
	at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:542)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:770)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:464)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:210)
Caused by: java.lang.RuntimeException: Unable to invoke method 'deactivate' for class org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator
	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeMethod(OsgiServiceUtil.java:347)
	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeLifecycleMethod(OsgiServiceUtil.java:234)
	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.activateDeactivate(OsgiServiceUtil.java:98)
	at org.apache.sling.testing.mock.osgi.MockOsgi.deactivate(MockOsgi.java:272)
	at org.apache.sling.testing.mock.osgi.MockBundleContext.shutdown(MockBundleContext.java:448)
	at org.apache.sling.testing.mock.osgi.MockOsgi.shutdown(MockOsgi.java:371)
	at org.apache.sling.testing.mock.osgi.context.OsgiContextImpl.tearDown(OsgiContextImpl.java:58)
	at org.apache.sling.testing.mock.sling.context.SlingContextImpl.tearDown(SlingContextImpl.java:256)
	at io.wcm.testing.mock.aem.context.AemContextImpl.tearDown(AemContextImpl.java:105)
	at io.wcm.testing.mock.aem.junit.AemContext.access$2(AemContext.java:1)
	at io.wcm.testing.mock.aem.junit.AemContext$3.execute(AemContext.java:216)
	at io.wcm.testing.mock.aem.junit.AemContext$3.execute(AemContext.java:1)
	at io.wcm.testing.junit.rules.parameterized.RepeatedStatement.evaluate(RepeatedStatement.java:65)
	... 18 more
Caused by: java.lang.NullPointerException
	at org.apache.sling.resourceresolver.impl.mapping.MapEntries.dispose(MapEntries.java:530)
	at org.apache.sling.resourceresolver.impl.CommonResourceResolverFactoryImpl.deactivate(CommonResourceResolverFactoryImpl.java:339)
	at org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator.unregisterFactory(ResourceResolverFactoryActivator.java:500)
	at org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator.unregisterFactory(ResourceResolverFactoryActivator.java:485)
	at org.apache.sling.resourceresolver.impl.ResourceResolverFactoryActivator.deactivate(ResourceResolverFactoryActivator.java:454)
	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.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeMethod(OsgiServiceUtil.java:338)
	... 30 more


{noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)