Uploaded image for project: 'Jackrabbit Oak'
  1. Jackrabbit Oak
  2. OAK-10610

Adding OSGi wiring test for SplitPersistenceService is failing

Attach filesAttach ScreenshotAdd voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Task
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • osgi, segment-tar
    • None

    Description

      While running the test in the patch attached, I always get:

      java.lang.RuntimeException: Unable to invoke method 'deactivate' for class org.apache.jackrabbit.oak.segment.osgi.SplitPersistenceService
      
      	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeMethod(OsgiServiceUtil.java:325)
      	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.invokeLifecycleMethod(OsgiServiceUtil.java:225)
      	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.activateDeactivate(OsgiServiceUtil.java:89)
      	at org.apache.sling.testing.mock.osgi.MockOsgi.deactivate(MockOsgi.java:231)
      	at org.apache.sling.testing.mock.osgi.MockBundleContext.shutdown(MockBundleContext.java:449)
      	at org.apache.sling.testing.mock.osgi.MockOsgi.shutdown(MockOsgi.java:330)
      	at org.apache.sling.testing.mock.osgi.context.OsgiContextImpl.tearDown(OsgiContextImpl.java:58)
      	at org.apache.sling.testing.mock.osgi.junit.OsgiContext.access$200(OsgiContext.java:35)
      	at org.apache.sling.testing.mock.osgi.junit.OsgiContext$1.after(OsgiContext.java:86)
      	at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:59)
      	at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:54)
      	at org.junit.runners.ParentRunner$<...>.invokeLifecycleMethod(OsgiServiceUtil.java:225)
      	at org.apache.sling.testing.mock.osgi.OsgiServiceUtil.activateDeactivate(OsgiServiceUtil.java:89)
      	at org.apache.sling.testing.mock.osgi.MockOsgi.deactivate(MockOsgi.java:231)
      	at org.apache.sling.testing.mock.osgi.MockOsgi.deactivate(MockOsgi.java:218)
      	at org.apache.sling.testing.mock.osgi.MockBundleContext.restartService(MockBundleContext.java:202)
      	at org.apache.sling.testing.mock.osgi.MockBundleContext.handleRefsUpdateOnUnregister(MockBundleContext.java:259)
      	at org.apache.sling.testing.mock.osgi.MockBundleContext.unregisterService(MockBundleContext.java:191)
      	at org.apache.sling.testing.mock.osgi.MockServiceRegistration.unregister(MockServiceRegistration.java:100)
      	at org.apache.jackrabbit.oak.osgi.OsgiWhiteboard$1.unregister(OsgiWhiteboard.java:87)
      	at org.apache.jackrabbit.oak.segment.osgi.SplitPersistenceService.deactivate(SplitPersistenceService.java:70)
      	at jdk.internal.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
      

      The problem is that there is a StackOverflowException being thrown when calling deactivate(). This might stem from the fact that SplitPersistenceService has a reference to the same type it tries to register, but this is only an assumption.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            adulceanu Andrei Dulceanu
            adulceanu Andrei Dulceanu

            Dates

              Created:
              Updated:

              Slack

                Issue deployment