Plugin isn't working with latest Bamboo (5.4.2)

Issue #27 on hold
Jeremy Goodwin created an issue

Hi,

we upgraded our Bamboo instance to 5.4.2 this week and now the TFS plugin is broken. Bamboo is giving the following error:

Unable to detect changes
(com.atlassian.bamboo.repository.RepositoryException : com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.NullPointerException)

If I try and look at my repositories, the plugin is showing as "invalid repository" and if I attempt to add a new TFS repository, the TFS option is not available. With the stack trace:

com.atlassian.bamboo.repository.RepositoryException: com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.NullPointerException
    at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuildInternal(DefaultChangeDetectionManager.java:371)
    at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceRevisions(DefaultChangeDetectionManager.java:259)
    at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceRevisions(DefaultChangeDetectionManager.java:154)
    at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuildIfTriggered(DefaultChangeDetectionManager.java:116)
    at com.atlassian.bamboo.v2.trigger.ChangeDetectionListenerAction.testIfBuildShouldStart(ChangeDetectionListenerAction.java:113)
    at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$3.call(PlanExecutionManagerImpl.java:481)
    at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$3.call(PlanExecutionManagerImpl.java:465)
    at com.atlassian.util.concurrent.ManagedLocks$ManagedLockImpl.withLock(ManagedLocks.java:312)
    at com.atlassian.bamboo.plan.PlanExecutionLockServiceImpl.lock(PlanExecutionLockServiceImpl.java:81)
    at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.doWithProcessLock(PlanExecutionManagerImpl.java:741)
    at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.startConditionalBuild(PlanExecutionManagerImpl.java:464)
    at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.start(PlanExecutionManagerImpl.java:535)
    at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.start(PlanExecutionManagerImpl.java:552)
    at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3.startPlanExecution(NonBlockingPlanExecutionServiceImpl.java:166)
    at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3$1.run(NonBlockingPlanExecutionServiceImpl.java:145)
    at com.atlassian.bamboo.util.CacheAwareness.whileReadingThroughCaches(CacheAwareness.java:85)
    at com.atlassian.bamboo.util.CacheAwareness.whileReadingThroughCaches(CacheAwareness.java:102)
    at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3.call(NonBlockingPlanExecutionServiceImpl.java:148)
    at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3.call(NonBlockingPlanExecutionServiceImpl.java:133)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
    at java.util.concurrent.FutureTask.run(FutureTask.java:166)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49)
    at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31)
    at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20)
    at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52)
    at java.lang.Thread.run(Thread.java:722)
Caused by: com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.NullPointerException
    at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149)
    at com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112)
    at com.atlassian.bamboo.repository.RepositoryDataImpl.getRepository(RepositoryDataImpl.java:136)
    at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuildInternal(DefaultChangeDetectionManager.java:311)
    ... 27 more
Caused by: java.lang.NullPointerException
    at com.atlassian.plugin.module.ClassPrefixModuleFactory.createModule(ClassPrefixModuleFactory.java:32)
    at com.atlassian.plugin.module.PrefixDelegatingModuleFactory.createModule(PrefixDelegatingModuleFactory.java:99)
    at com.atlassian.bamboo.plugin.descriptor.AbstractBambooModuleDescriptor.createModule(AbstractBambooModuleDescriptor.java:28)
    at com.atlassian.bamboo.plugin.descriptor.AbstractBambooModuleDescriptor.access$000(AbstractBambooModuleDescriptor.java:15)
    at com.atlassian.bamboo.plugin.descriptor.AbstractBambooModuleDescriptor$2.call(AbstractBambooModuleDescriptor.java:102)
    at com.atlassian.bamboo.plugin.BambooPluginUtils.callUnsafeCode(BambooPluginUtils.java:86)
    at com.atlassian.bamboo.plugin.descriptor.AbstractBambooModuleDescriptor.getModule(AbstractBambooModuleDescriptor.java:111)
    at com.atlassian.bamboo.plugin.descriptor.RepositoryModuleDescriptor.getModule(RepositoryModuleDescriptor.java:43)
    at com.atlassian.bamboo.plugin.descriptor.RepositoryModuleDescriptor.getModule(RepositoryModuleDescriptor.java:18)
    at com.atlassian.bamboo.repository.DefaultRepositoryManager.getNewRepositoryInstance(DefaultRepositoryManager.java:50)
    at com.atlassian.bamboo.repository.RepositoryReference.create(RepositoryReference.java:25)
    at com.atlassian.bamboo.repository.RepositoryReference.create(RepositoryReference.java:10)
    at com.atlassian.util.concurrent.LazyReference$Sync.run(LazyReference.java:321)
    at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:143)
    ... 30 more

Comments (6)

  1. Jeremy Goodwin reporter

    From looking at the Bamboo log file, we're getting a license exception:

    2014-03-12 10:16:05,923 ERROR [4-BAM::PlanExec:pool-8-thread-3] [TfsRepository] Caught an exception: 
    com.atlassian.license.LicenseException: [Tfs Repository] The current license status cannot be retrieved because the Plugin License Storage plugin is unavailable. Please speak to a system administrator.
        at com.stellarity.bamboo.repository.TfsRepository.checkLicense(TfsRepository.java:856)
        at com.stellarity.bamboo.repository.TfsRepository.collectChangesSinceLastBuild(TfsRepository.java:169)
        at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectionChangesWithRetry(DefaultChangeDetectionManager.java:470)
        at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuildInternal(DefaultChangeDetectionManager.java:331)
        at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceRevisions(DefaultChangeDetectionManager.java:259)
        at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceRevisions(DefaultChangeDetectionManager.java:154)
        at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuildIfTriggered(DefaultChangeDetectionManager.java:116)
        at com.atlassian.bamboo.v2.trigger.ChangeDetectionListenerAction.testIfBuildShouldStart(ChangeDetectionListenerAction.java:113)
        at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$3.call(PlanExecutionManagerImpl.java:481)
        at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$3.call(PlanExecutionManagerImpl.java:465)
        at com.atlassian.util.concurrent.ManagedLocks$ManagedLockImpl.withLock(ManagedLocks.java:312)
        at com.atlassian.bamboo.plan.PlanExecutionLockServiceImpl.lock(PlanExecutionLockServiceImpl.java:81)
        at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.doWithProcessLock(PlanExecutionManagerImpl.java:741)
        at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.startConditionalBuild(PlanExecutionManagerImpl.java:464)
        at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.start(PlanExecutionManagerImpl.java:535)
        at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.start(PlanExecutionManagerImpl.java:552)
        at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3.startPlanExecution(NonBlockingPlanExecutionServiceImpl.java:166)
        at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3$1.run(NonBlockingPlanExecutionServiceImpl.java:145)
        at com.atlassian.bamboo.util.CacheAwareness.whileReadingThroughCaches(CacheAwareness.java:85)
        at com.atlassian.bamboo.util.CacheAwareness.whileReadingThroughCaches(CacheAwareness.java:102)
        at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3.call(NonBlockingPlanExecutionServiceImpl.java:148)
        at com.atlassian.bamboo.plan.NonBlockingPlanExecutionServiceImpl$3.call(NonBlockingPlanExecutionServiceImpl.java:133)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49)
        at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31)
        at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20)
        at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52)
        at java.lang.Thread.run(Thread.java:722)
    

    From looking at the plugin within "Manage add-ons", the license is fine.

  2. Sergey Podobry

    Hi Jeremy,

    I've retested with Bamboo 5.4.2 and it works fine.

    Could you provide more information about your setup? I want to know your upgrade path (which Bamboo version did you have before?) and current Bamboo system information (Bamboo Admin->System->System information).

  3. Jeremy Goodwin reporter

    Just as an additional update, uninstalling the plugin, restarting the server, re-installing the plugin and restarting the server again hass fixed the problem.

  4. Log in to comment