java.lang.ClassNotFoundException when triggering Bamboo integration functionalities
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
Integration with Bamboo stops working - i.e. triggers, creation of new branches - and the following appears in the atlassian-bitbucket.log:
2015-06-09 13:00:00,000 ERROR [AtlassianEvent::thread-6] c.a.s.i.e.AsyncBatchingInvokersTransformer There was an exception thrown trying to dispatch event
'com.atlassian.devstatus.IssueChangedEvent@2a302503[issueKeys=[ISSUE-200],sourceId=<null>,sourceUrl=<null>]' for the invoker 'SingleParameterMethodListenerInvoker{method=public void
com.atlassian.event.remote.impl.RemoteEventListener.onRemoteEvent(com.atlassian.event.remote.RemoteEvent), listener=com.atlassian.event.remote.impl.RemoteEventListener@7e5ad074}'.
java.lang.RuntimeException: java.lang.NoClassDefFoundError: com/atlassian/event/remote/RemoteEvent
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:54) ~[atlassian-event-2.3.5.jar:na]
at com.atlassian.stash.internal.event.AsyncBatchingInvokersTransformer$AsyncInvokerBatch.invoke(AsyncBatchingInvokersTransformer.java:100) ~[stash-platform-3.9.2.jar:na]
at com.atlassian.event.internal.AsynchronousAbleEventDispatcher$1$1.run(AsynchronousAbleEventDispatcher.java:48) [atlassian-event-2.3.5.jar:na]
at com.atlassian.sal.core.executor.ThreadLocalDelegateRunnable.run(ThreadLocalDelegateRunnable.java:38) [sal-core-2.13.4.jar:na]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_75]
at java.lang.Thread.run(Thread.java:745) [na:1.7.0_75]
... 1 frame trimmed
Caused by: com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.NoClassDefFoundError: com/atlassian/event/remote/RemoteEvent
at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149) ~[atlassian-util-concurrent-2.6.3.jar:na]
at com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112) ~[atlassian-util-concurrent-2.6.3.jar:na]
at com.atlassian.util.concurrent.ResettableLazyReference.get(ResettableLazyReference.java:92) ~[atlassian-util-concurrent-2.6.3.jar:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar.isRegistered(DefaultRemoteEventProducerRegistrar.scala:26) ~[na:na]
at com.atlassian.event.remote.impl.RemoteEventListener.onRemoteEvent(RemoteEventListener.scala:67) ~[na:na]
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:36) ~[atlassian-event-2.3.5.jar:na]
... 6 common frames omitted
Caused by: java.lang.NoClassDefFoundError: com/atlassian/event/remote/RemoteEvent
at java.lang.ClassLoader.defineClass1(Native Method) ~[na:1.7.0_75]
at com.atlassian.stash.internal.jira.index.impl.IssueChangesetIndexer.produces(IssueChangesetIndexer.scala:51) ~[na:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar$$anon$2$$anonfun$create$1.apply(DefaultRemoteEventProducerRegistrar.scala:21) ~[na:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar$$anon$2$$anonfun$create$1.apply(DefaultRemoteEventProducerRegistrar.scala:21) ~[na:na]
at scala.collection.TraversableLike$$anonfun$flatMap$1.apply(TraversableLike.scala:251) ~[na:na]
at scala.collection.TraversableLike$$anonfun$flatMap$1.apply(TraversableLike.scala:251) ~[na:na]
at scala.collection.mutable.HashSet.foreach(HashSet.scala:79) ~[na:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar$$anon$1.scala$collection$mutable$SynchronizedSet$$super$foreach(DefaultRemoteEventProducerRegistrar.scala:16) ~[na:na]
at scala.collection.mutable.SynchronizedSet$class.foreach(SynchronizedSet.scala:82) ~[na:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar$$anon$1.foreach(DefaultRemoteEventProducerRegistrar.scala:16) ~[na:na]
at scala.collection.TraversableLike$class.flatMap(TraversableLike.scala:251) ~[na:na]
at scala.collection.AbstractTraversable.flatMap(Traversable.scala:105) ~[na:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar$$anon$2.create(DefaultRemoteEventProducerRegistrar.scala:21) ~[na:na]
at com.atlassian.event.remote.impl.DefaultRemoteEventProducerRegistrar$$anon$2.create(DefaultRemoteEventProducerRegistrar.scala:19) ~[na:na]
at com.atlassian.util.concurrent.ResettableLazyReference$InternalReference.create(ResettableLazyReference.java:182) ~[atlassian-util-concurrent-2.6.3.jar:na]
at com.atlassian.util.concurrent.LazyReference$Sync.run(LazyReference.java:325) ~[atlassian-util-concurrent-2.6.3.jar:na]
at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:143) ~[atlassian-util-concurrent-2.6.3.jar:na]
... 11 common frames omitted
Caused by: java.lang.ClassNotFoundException: com.atlassian.event.remote.RemoteEvent not found by com.atlassian.stash.dev-summary-plugin [60]
at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:812) ~[org.apache.felix.framework-3.2.2.jar:na]
... 27 common frames omitted
Cause
The RemoteEvent
class from the dev-summary-plugin
was not loaded correctly during the last startup.
Resolution
- Shut Bitbucket Server down.
- Backup and remove the following directories. They will be rebuilt when Bitbucket Server starts again.
$BITBUCKET_HOME
/plugins/.bundled-plugins/$BITBUCKET_HOME
/plugins/.osgi-cache/
- Restart Bitbucket Server.