java.lang.IllegalStateException: a disposer has not been initialized for this thread

Atlassian JIRA | Lukasz Pater | 3 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    If the thread calling ReviewService doesn't have a disposer defined (for example didn't come through CrucibleFilter), calling some methods of ReviewService will cause an exception. {code} java.lang.IllegalStateException: a disposer has not been initialized for this thread at com.cenqua.fisheye.util.Disposer.threadInstance(Disposer.java:100) at com.cenqua.fisheye.rep.RepositoryHandle.acquireEngine(RepositoryHandle.java:477) at com.cenqua.crucible.revision.source.RepositorySource.<init>(RepositorySource.java:111) at com.cenqua.crucible.revision.source.DefaultSourceFactory.makeRepositorySource(DefaultSourceFactory.java:99) at com.cenqua.crucible.revision.source.DefaultSourceFactory.makeSource(DefaultSourceFactory.java:95) at com.cenqua.crucible.revision.source.DefaultSourceFactory.getSource(DefaultSourceFactory.java:71) at com.atlassian.crucible.spi.impl.DefaultReviewService$6.doInTransaction(DefaultReviewService.java:581) at com.atlassian.crucible.spi.impl.DefaultReviewService$6.doInTransaction(DefaultReviewService.java:574) at com.atlassian.fisheye.spi.impl.DefaultTxTemplate.execute(DefaultTxTemplate.java:126) at com.atlassian.fisheye.spi.impl.DefaultTxTemplate.execute(DefaultTxTemplate.java:114) ... at com.atlassian.crucible.spi.impl.DefaultReviewService.addChangesetsToReview(DefaultReviewService.java:574) ... {code} A workaround is to manage the Disposer manually, but that's not api nor should it be exposed to the user.

    Atlassian JIRA | 3 years ago | Lukasz Pater
    java.lang.IllegalStateException: a disposer has not been initialized for this thread
  2. 0

    If the thread calling ReviewService doesn't have a disposer defined (for example didn't come through CrucibleFilter), calling some methods of ReviewService will cause an exception. {code} java.lang.IllegalStateException: a disposer has not been initialized for this thread at com.cenqua.fisheye.util.Disposer.threadInstance(Disposer.java:100) at com.cenqua.fisheye.rep.RepositoryHandle.acquireEngine(RepositoryHandle.java:477) at com.cenqua.crucible.revision.source.RepositorySource.<init>(RepositorySource.java:111) at com.cenqua.crucible.revision.source.DefaultSourceFactory.makeRepositorySource(DefaultSourceFactory.java:99) at com.cenqua.crucible.revision.source.DefaultSourceFactory.makeSource(DefaultSourceFactory.java:95) at com.cenqua.crucible.revision.source.DefaultSourceFactory.getSource(DefaultSourceFactory.java:71) at com.atlassian.crucible.spi.impl.DefaultReviewService$6.doInTransaction(DefaultReviewService.java:581) at com.atlassian.crucible.spi.impl.DefaultReviewService$6.doInTransaction(DefaultReviewService.java:574) at com.atlassian.fisheye.spi.impl.DefaultTxTemplate.execute(DefaultTxTemplate.java:126) at com.atlassian.fisheye.spi.impl.DefaultTxTemplate.execute(DefaultTxTemplate.java:114) ... at com.atlassian.crucible.spi.impl.DefaultReviewService.addChangesetsToReview(DefaultReviewService.java:574) ... {code} A workaround is to manage the Disposer manually, but that's not api nor should it be exposed to the user.

    Atlassian JIRA | 3 years ago | Lukasz Pater
    java.lang.IllegalStateException: a disposer has not been initialized for this thread

    Root Cause Analysis

    1. java.lang.IllegalStateException

      a disposer has not been initialized for this thread

      at com.cenqua.fisheye.util.Disposer.threadInstance()
    2. com.cenqua.fisheye
      RepositoryHandle.acquireEngine
      1. com.cenqua.fisheye.util.Disposer.threadInstance(Disposer.java:100)
      2. com.cenqua.fisheye.rep.RepositoryHandle.acquireEngine(RepositoryHandle.java:477)
      2 frames
    3. com.cenqua.crucible
      DefaultSourceFactory.getSource
      1. com.cenqua.crucible.revision.source.RepositorySource.<init>(RepositorySource.java:111)
      2. com.cenqua.crucible.revision.source.DefaultSourceFactory.makeRepositorySource(DefaultSourceFactory.java:99)
      3. com.cenqua.crucible.revision.source.DefaultSourceFactory.makeSource(DefaultSourceFactory.java:95)
      4. com.cenqua.crucible.revision.source.DefaultSourceFactory.getSource(DefaultSourceFactory.java:71)
      4 frames
    4. com.atlassian.crucible
      DefaultReviewService$6.doInTransaction
      1. com.atlassian.crucible.spi.impl.DefaultReviewService$6.doInTransaction(DefaultReviewService.java:581)
      2. com.atlassian.crucible.spi.impl.DefaultReviewService$6.doInTransaction(DefaultReviewService.java:574)
      2 frames
    5. com.atlassian.fisheye
      DefaultTxTemplate.execute
      1. com.atlassian.fisheye.spi.impl.DefaultTxTemplate.execute(DefaultTxTemplate.java:126)
      2. com.atlassian.fisheye.spi.impl.DefaultTxTemplate.execute(DefaultTxTemplate.java:114)
      2 frames