Bitbucket Server is not starting due to FastMethodInterceptorDelegatorBoot class not found
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
Summary
After attempting to add the AppDynamics java agent, Bitbucket Server fails to start.
Environment
- Bitbucket Server or Data Center
- AppDynamics Java Agent
Diagnosis
The following appears in the atlassian-bitbucket.log
file after the failed Bitbucket start was attempted:
ERROR [FelixDispatchQueue] c.a.p.o.c.f.FelixOsgiContainerManager Framework error in bundle org.eclipse.gemini.blueprint.extender
org.osgi.framework.BundleException: Activator start error in bundle org.eclipse.gemini.blueprint.extender [18].
at org.apache.felix.framework.Felix.activateBundle(Felix.java:2196)
at java.lang.Thread.run(Thread.java:745)
... 3 frames trimmed
Caused by: java.lang.NoClassDefFoundError: com/singularity/ee/agent/appagent/entrypoint/bciengine/FastMethodInterceptorDelegatorBoot
Cause
The OSGi boot delegation is not configured correctly and is causing the startup to fail.
Solution
- Update the
JVM_SUPPORT_RECOMMENDED_ARGS
variable (in the_start-webapp.sh
/_start-webapp.bat
file located in$BITBUCKET_HOME/bin
) by adding theatlassian.org.osgi.framework.bootdelegation.extra
option with the following value:
-Datlassian.org.osgi.framework.bootdelegation.extra=com.singularity.*
- Restart Bitbucket Server
After applying this change, your JVM_SUPPORT_RECOMMENDED_ARGS
variable may look something like:
JVM_SUPPORT_RECOMMENDED_ARGS="-javaagent:/path/to/appdynamics/java-agent/javaagent.jar -Dappdynamics.agent.tierName=SOMETHING_HERE -Dappdynamics.agent.nodeName=SOMETHING_HERE -Datlassian.org.osgi.framework.bootdelegation.extra=com.singularity.*"
If using the above example, be sure to add any other needed settings (based on your team's existing settings for this variable), as well as modify the above -
Dappdynamics.*
and -
javaagent
arguments to match your company's desired values.